BaseChangePointsModelAdapter

class BaseChangePointsModelAdapter[source]

Bases: etna.core.mixins.BaseMixin, abc.ABC

BaseChangePointsModelAdapter is the base class for change point models adapters.

Inherited-members

Methods

get_change_points(df, in_column)

Find change points within one segment.

get_change_points_intervals(df, in_column)

Find change point intervals in given dataframe and column.

set_params(**params)

Return new object instance with modified parameters.

to_dict()

Collect all information about etna object in dict.

abstract get_change_points(df: pandas.core.frame.DataFrame, in_column: str) List[pandas._libs.tslibs.timestamps.Timestamp][source]

Find change points within one segment.

Parameters
  • df (pandas.core.frame.DataFrame) – dataframe indexed with timestamp

  • in_column (str) – name of column to get change points

Returns

change point timestamps

Return type

change points

get_change_points_intervals(df: pandas.core.frame.DataFrame, in_column: str) List[Tuple[pandas._libs.tslibs.timestamps.Timestamp, pandas._libs.tslibs.timestamps.Timestamp]][source]

Find change point intervals in given dataframe and column.

Parameters
  • df (pandas.core.frame.DataFrame) – dataframe indexed with timestamp

  • in_column (str) – name of column to get change points

Returns

change points intervals

Return type

List[Tuple[pandas._libs.tslibs.timestamps.Timestamp, pandas._libs.tslibs.timestamps.Timestamp]]