Skip to main content

cointegration

Show co-integration between two timeseries using the two step Engle-Granger test.

The two-step Engle-Granger test is a method designed to detect co-integration between two time series. Co-integration is a statistical property indicating that two or more time series move together over the long term, even if they are individually non-stationary. This concept is crucial in economics and finance, where identifying pairs or groups of assets that share a common stochastic trend can inform long-term investment strategies and risk management practices. The Engle-Granger test first checks for a stable, long-term relationship by regressing one time series on the other and then tests the residuals for stationarity. If the residuals are found to be stationary, it suggests that despite any short-term deviations, the series are bound by an equilibrium relationship over time.

Parameters

data: list[openbb_core.provider.abstract.data.Data]

Input dataset.

Optional: False


columns: list[str]

Data columns to check cointegration

Optional: False


maxlag: PositiveInt

Number of lags to use in the test.

Optional: False


Returns

results: list[Data]

Serializable results.


provider: None

Provider name.


warnings: Optional[list[Warning_]]

list of warnings.


chart: Optional[Chart]

Chart object.


extra: dict[str, Any]

Extra info.


On this page