, interval_label, start, end)[source]

Adjusts the index of the data depending on the interval_label, start, and end. Will always return the data located between start, end.

  • data (pandas.Series or pandas.DataFrame) – The data with a localized DatetimeIndex
  • interval_label (str or None) – The interval label for the the object the data represents
  • start (pandas.Timestamp) – Start time to restrict data to
  • end (pandas.Timestamp) – End time to restrict data to

pandas.Series or pandas.DataFrame – Return data between start and end, in/excluding the endpoints depending on interval_label


ValueError – If an invalid interval_label is given or data is not localized.