docstr: Returns a sliced DataFrame
  
  Parameters
  ----------
          slice : tuple(from,to)
                  from : str - ie ('01Jan2019')
                  to : str - ie ('01Jan2020')
                          States the 'from' and 'to' values which 
                          will get rendered as df.loc[from:to]
          df : DataFrame
                  If omitted then the QuantFigure.DataFrame is resampled.
docstr_tok: ["Returns","a","sliced","DataFrame","Parameters","--","--","--","--","--","slice",":","tuple","(","from",",","to",")","from",":","str","-","ie","(","'01Jan2019","'",")","to",":","str","-","ie","(","'01Jan2020","'",")","States","the","'from","'","and","'to","'","values","which","will","get","rendered","as","df.loc","[","from",":","to","]","df",":","DataFrame","If","omitted","then","the","QuantFigure.DataFrame","is","resampled","."]
code: def _get_sliced(
      self, slice, df=None, to_strfmt="%Y-%m-%d", from_strfmt="%d%b%y"
  ):
      """
      Returns a sliced DataFrame
  
      Parameters
      ----------
              slice : tuple(from,to)
                      from : str - ie ('01Jan2019')
                      to : str - ie ('01Jan2020')
                              States the 'from' and 'to' values which
                              will get rendered as df.loc[from:to]
              df : DataFrame
                      If omitted then the QuantFigure.DataFrame is resampled.
      """
  
      df = self.df.copy() if df == None else df
      if type(slice) not in (list, tuple):
          raise Exception("Slice must be a tuple two values")
      if len(slice) != 2:
          raise Exception("Slice must be a tuple two values")
      a, b = slice
      a = None if a in ("", None) else utils.make_string(a)
      b = None if b in ("", None) else utils.make_string(b)
      if a:
          a = (
              date_tools.stringToString(a, from_strfmt, to_strfmt)
              if "-" not in a
              else a
          )
      if b:
          b = (
              date_tools.stringToString(b, from_strfmt, to_strfmt)
              if "-" not in b
              else b
          )
  
      return df.loc[a:b]
  
imports: from __future__ import absolute_import
  import plotly.graph_objs
  import json
  import copy
  import pandas
  from .plotlytools import iplot
  from .None import tools
  from .None import ta
  from .None import utils
  from .None import colors
  from .None import auth
  from .None import date_tools
label_desc: Use image node_id 3 for calling the QuantFig obj's underlying member method code with example usage: obj._get_sliced(slice, df, to_strfmt, from_strfmt) and returns: df