Definition
A Markov-switching (or regime-switching) model is a state-space model in which the parameters governing the observation density depend on a discrete latent state St that evolves as a first-order Markov chain. Conditional on the regime, the data are described by an ordinary linear-Gaussian model; marginally, the model captures abrupt structural shifts — recessions, exchange-rate regimes, high- vs. low-volatility episodes — that a single-regime model cannot. Introduced to econometrics by Hamilton (1989), the framework replaces the continuous latent state of a linear state-space model with a finite collection of regimes, so the conditional likelihood is computed by a discrete analogue of the Kalman filter known as Hamilton's filter.
Key Ideas
- Discrete latent state: The unobserved regime St∈{1,…,m} indexes which parameter vector θSt generates yt. The observation density is f(yt∣Yt−1,St=j,θ) — a single-regime model conditional on St.
- First-order Markov transition: Regimes persist according to a transition matrix P=[pij] with pij=Pr(St=j∣St−1=i) and ∑jpij=1. Expected regime duration is 1/(1−pii).
- State-space grounding: A Markov-switching model is a non-linear, non-Gaussian state-space model whose state is categorical rather than continuous. When a continuous latent component (e.g. an unobserved-components trend) is also present, the two states are filtered jointly and the exact mixture filter is approximated by the Kim (1994) filter — the regime-switching counterpart of the Kalman filter.
- Model taxonomy: Regimes may shift the conditional mean (switching-mean models, Hamilton 1989), the innovation variance (switching-variance / Markov heteroskedasticity), the autoregressive (AR) dynamics, or any block of these independently.
- Identification and label switching: Regime labels are exchangeable, so an ordering or sign restriction (e.g. μ1<μ2, or "state 1 = high variance") is needed to pin down a unique parameterisation — exactly as in the Mixture Model.
- The unidentified-nuisance-parameter problem: Under the null of a single regime, the transition probabilities are unidentified ("nuisance parameters present only under the alternative"), so the likelihood-ratio statistic does not have a standard χ2 distribution (Davies 1977; Hansen 1992).
How It Works
State-Space Form
The canonical Hamilton (1989) switching-mean autoregression writes a series as deviations from a regime-dependent mean:
yt−μSt=k=1∑rϕk(yt−k−μSt−k)+εt,εt∼N(0,σ2)
with μSt=μ0+μ1St and St∈{0,1}. The pair (observation equation, Markov state equation) is a state-space system; the only departure from the linear-Gaussian case is that the "state" St is discrete.
Hamilton's Filter (Conditional Likelihood)
The filter recursively tracks the probability of each regime given data through t. Starting from the chain's stationary distribution:
- Prediction: Pr(St=j∣Yt−1)=∑ipijPr(St−1=i∣Yt−1)
- Update after observing yt:
Pr(St=j∣Yt)=∑kf(yt∣St=k,Yt−1)Pr(St=k∣Yt−1)f(yt∣St=j,Yt−1)Pr(St=j∣Yt−1)
The denominator is the one-step predictive density of yt, so the sample log-likelihood accumulates as
ℓ(θ)=t=1∑Tlog[j∑f(yt∣St=j,Yt−1)Pr(St=j∣Yt−1)],
which is maximised numerically to obtain the maximum likelihood estimator (MLE). This parallels the Kalman filter's prediction-error decomposition, with summation over discrete regimes replacing the Gaussian integral.
Smoothing
Full-sample regime inference Pr(St=j∣YT) comes from a backward pass (Kim 1994 smoother), the discrete analogue of the Rauch-Tung-Striebel Kalman smoother.
Estimation Strategies
- Maximum likelihood via Hamilton's filter for pure regime-switching models; the Kim filter adds a collapsing step when continuous and discrete states coexist (e.g. unobserved-components models), keeping the Gaussian-mixture count bounded.
- Bayesian via Data Augmentation: treat the regime path S1:T as missing data and sample it inside a Gibbs Sampler. Albert-Chib (1993) draw each St from its full conditional; Chib (1996) draws the whole path jointly via a forward-filter/backward-sample (FFBS) recursion — the discrete-state analogue of the Carter-Kohn (1994) simulation smoother — sharply reducing autocorrelation. Conditional on S1:T, the regime-specific parameters and the transition matrix have conjugate (Normal, Inverse-Gamma, Dirichlet/Beta) posteriors.
Why It Matters
- Provides a parsimonious, interpretable way to model abrupt change — turning points, policy regimes, volatility states — without the over-parameterisation of fully time-varying-parameter models.
- The filter delivers, as a by-product, smoothed regime probabilities that date events directly (e.g. recession dates matching the National Bureau of Economic Research (NBER) chronology).
- Markov-switching heteroskedasticity is a known confound for classical inference: it inflates the size of unit-root tests and mimics the near-unit-root persistence of generalized autoregressive conditional heteroskedasticity (GARCH), so failing to model it leads to spurious conclusions about persistence and integration.
- It is the shared engine behind a family of applied models in this wiki — the Markov-Switching VAR, the Plucking Model, the Great Moderation break analysis, and Markov-switching treatments of Purchasing Power Parity.
Open Questions
- Choosing the number of regimes m: testing m vs. m+1 regimes is non-standard because of the unidentified-nuisance-parameter problem; marginal-likelihood / Bayes-factor comparison is the principled but costly alternative.
- Specifying transition dynamics: fixed transition probabilities can be generalised to duration-dependent or covariate-driven (time-varying) transitions, at the cost of identification and computation.
- Scaling to large systems: the number of regime-specific parameters grows quickly with the cross-sectional dimension, limiting multivariate applications.
Related