VECMResult.stability_check#
- VECMResult.stability_check()[source]#
Assess the levels companion, permitting the unit roots by design.
A rank-
rsystem inkvariables carries exactlyk - runit 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_stabletrue when no root lies outside the unit circle andn_unit_rootscounting 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)