MinMaxDifferenceTransform

class MinMaxDifferenceTransform(in_column: str, window: int, seasonality: int = 1, min_periods: int = 1, fillna: float = 0, out_column: Optional[str] = None)[source]

Bases: etna.transforms.math.statistics.WindowStatisticsTransform

MinMaxDifferenceTransform computes difference between max and min values for given window.

Init MaxTransform.

Parameters
  • in_column (str) – name of processed column

  • window (int) – size of window to aggregate

  • seasonality (int) – seasonality of lags to compute window’s aggregation with

  • min_periods (int) – min number of targets in window to compute aggregation; if there is less than min_periods number of targets return None

  • fillna (float) – value to fill results NaNs with

  • out_column (str, optional) – result column name. If not given use self.__repr__()

Inherited-members

Methods

fit(ts)

Fit the transform.

fit_transform(ts)

Fit and transform TSDataset.

get_regressors_info()

Return the list with regressors created by the transform.

inverse_transform(ts)

Inverse transform TSDataset.

load(path)

Load an object.

params_to_tune()

Get default grid for tuning hyperparameters.

save(path)

Save the object.

set_params(**params)

Return new object instance with modified parameters.

to_dict()

Collect all information about etna object in dict.

transform(ts)

Transform TSDataset inplace.