VECMResult.stability_check#

VECMResult.stability_check()[source]#

Assess the levels companion, permitting the unit roots by design.

A rank-r system in k variables carries exactly k - r unit roots. Treating those as instability, which the reduced-form check does, would flag every correctly specified model in this family.

Return type:

_StabilityAssessment

Returns:

The assessment of the levels companion matrix, with is_stable true when no root lies outside the unit circle and n_unit_roots counting the ones on it.

Example

>>> import numpy as np
>>> rng = np.random.default_rng(0)
>>> common = np.cumsum(rng.standard_normal(300))
>>> y = np.column_stack([common, 2 * common + rng.standard_normal(300)])
>>> check = VECM(y, order=2, rank=1).fit().stability_check()
>>> check.is_stable, check.n_unit_roots, check.n_explosive
(True, 1, 0)