MarkovSwitchingVARResult.regime_shares#
- property MarkovSwitchingVARResult.regime_shares: NDArray[float64][source]#
Average smoothed probability of each regime over the sample.
Example
>>> import numpy as np >>> rng = np.random.default_rng(0) >>> s = np.repeat([0, 1, 0, 1], 100) >>> y = np.array([[-1.0, -0.5], [1.5, 1.0]])[s] + 0.4 * rng.standard_normal((400, 2)) >>> res = MarkovSwitchingVAR(y, order=1, n_regimes=2).fit(seed=0) >>> res.regime_shares.round(2), bool(np.isclose(res.regime_shares.sum(), 1.0)) (array([0.5, 0.5]), True)