change_span¶
-
hhpy.ds.
change_span
(s: pandas.core.series.Series, steps: int = 5) → pandas.core.series.Series[source]¶ return a True/False series around a changepoint, used for filtering stepwise data series in a pandas df must be properly sorted!
Parameters: - s – pandas Series or similar
- steps – number of steps around the changepoint to flag as true
Returns: pandas Series of dtype Boolean