Param Estimator
StationarityZivotAndrews
Test for stationarity via the Zivot-Andrews Unit Root Test.
Quickstart
python
from sktime.param_est.stationarity import StationarityZivotAndrews
estimator = StationarityZivotAndrews(lags=None, trend='c', trim=0.15, max_lags=None, method='aic', p_threshold=0.05)Parameters(5)
- lagsint, optional
The number of lags to use in the ADF regression. If omitted or None,
methodis used to automatically select the lag length with no more thanmax_lagsare included.- trend{“c”, “t”, “ct”}, optional
The trend component to include in the test
“c” - Include a constant (Default)
“t” - Include a linear time trend
“ct” - Include a constant and linear time trend
- trimfloat
- percentage of series at begin/end to exclude from break-period calculation in range [0, 0.333] (default=0.15)
- max_lagsint, optional
- The maximum number of lags to use when selecting lag length
- method{“AIC”, “BIC”, “t-stat”}, optional
The method to use when selecting the lag length
“AIC” - Select the minimum of the Akaike IC
“BIC” - Select the minimum of the Schwarz/Bayesian IC
“t-stat” - Select the minimum of the Schwarz/Bayesian IC
Examples
>>> from sktime.datasets import load_airline
>>> from sktime.param_est.stationarity import StationarityZivotAndrews
>>>
>>> X = load_airline ()
>>> sty_est = StationarityZivotAndrews ()
>>> sty_est. fit (X) StationarityZivotAndrews(
... )
>>> sty_est. get_fitted_params ()["stationary" ] False