Bull, Bear, Sideways: 5 Ways to Detect Market Regimes
Five methods for detecting market regimes: rolling volatility, HMM, Markov-switching GARCH, supervised classification on macro features, and changepoint detection. When to use each and where they fail.
The biggest single mistake in quantitative trading is treating the market as if it were one thing. It is not. Markets cycle through regimes, sustained periods with distinct statistical properties, and a strategy that ignores regime structure is making a bet that the future will look like a weighted average of all past regimes, which it will not. Regime detection is the routing layer that decides which strategy variant to deploy in current conditions, and there are several reasonable ways to do it.
This article reviews five regime detection methods used in practice. Each has strengths and weaknesses. No single method dominates; the best applications combine two or three.
Method 1: Rolling volatility cuts
The simplest regime detector divides time into "low vol," "medium vol," and "high vol" buckets based on rolling realized volatility. Compute 20-day or 60-day realized vol; rank within history; assign to bucket. The result is a regime label per period that captures the basic volatility-of-volatility structure in equities.
Strengths: simple, robust, no hyperparameters beyond the rolling window. Strong baseline that is hard to beat without significantly more model complexity. Easy to communicate to non-technical stakeholders.
Weaknesses: ignores mean returns (a high-vol regime can be a crash regime or a melt-up regime, the volatility metric does not distinguish). Discrete bucket boundaries create discontinuities. Does not provide uncertainty estimates.
When to use: as a baseline and as a feature in more sophisticated models. Almost every regime-conditioned strategy starts with a volatility cut and adds refinements on top.
Method 2: Hidden Markov Models
HMMs treat regime as a latent state and infer it from observed returns. The model has K hidden states (typically 2 or 3), each with its own mean and variance, and a transition matrix governing how the system moves between states. Fitting is via Baum-Welch.
Strengths: provides probabilistic state inference rather than hard labels. Distinguishes high-vol-bullish from high-vol-bearish regimes through the per-state means. Naturally handles uncertainty: when the system is between regimes, the posterior is spread across states rather than forcing a binary call.
Weaknesses: assumes Gaussian emissions, which is at best approximate for daily returns. Fitting requires multiple random initializations to find the global optimum. The choice of K matters and is hard to nail down.
When to use: as the primary regime detector for ML ensembles and strategy-routing pipelines. We covered the details in our blog post on HMMs for trading.
Method 3: Markov-switching GARCH
MS-GARCH extends HMM with a GARCH-style volatility process within each regime. Instead of constant variance per state, the variance evolves according to a GARCH(1,1) recursion, but with regime-specific parameters. The hidden state still follows a Markov chain, but observations are now generated from a regime-conditional GARCH process.
Strengths: captures volatility clustering within regimes as well as regime-level mean shifts. Better fit to daily equity data than vanilla HMM because volatility clustering is real and important. Useful for option pricing and tail-risk applications.
Weaknesses: substantially more complex to fit than HMM. Convergence is unreliable without good initialization. Often overkill for applications where you only need regime labels, vanilla HMM produces nearly identical labels with simpler fitting.
When to use: when you need both regime detection and a volatility model that respects clustering. Common in option-pricing and risk-management applications.
Method 4: Supervised classification on macro features
Train a classifier (logistic regression, random forest, or gradient boosting) to predict regime labels from macroeconomic features: yield curve shape, credit spreads, VIX level, dollar strength, sector rotation, employment data, and inflation expectations. The labels can be defined ex-post (e.g., recession dates from NBER, drawdown periods longer than 6 months) or generated by one of the other methods on this list.
Strengths: incorporates information beyond price/return data, macro indicators are leading and can pick up regime changes before returns do. Provides feature importance, which helps with model interpretation and storytelling. Forecast-friendly: can produce next-period regime predictions.
Weaknesses: requires labeled training data, which means committing to a regime definition that may be wrong. Macro features have lags and revisions. The macro-to-regime mapping changes across decades, the yield curve had different predictive power before and after 2008.
When to use: when you need leading regime predictions and have access to clean macro data. Complementary to HMM (which is reactive), combining macro classifier output with HMM state probabilities yields the best of both.
Method 5: Changepoint detection
Changepoint methods (Bayesian changepoint detection, PELT, Wild Binary Segmentation) detect the precise points in time when the statistical properties of a series change. Unlike HMM, which assumes a fixed number of regimes and infers smooth probabilities, changepoint methods produce hard boundaries, "the regime changed on this date."
Strengths: produces precise event dates that can be used for retrospective analysis. Useful for one-shot regime-change detection (e.g., identifying the start of a bear market). Does not require a fixed K, the number of regimes is data-driven.
Weaknesses: latency is an issue for online use, most changepoint methods have a detection lag of weeks to months for daily data. Not suited for real-time strategy routing. False positives can be high without careful prior choice (in Bayesian methods) or penalty tuning (in PELT).
When to use: for retrospective analysis, regime labeling of historical data, and ex-post backtesting design. Less useful for live trading.
Combining methods in practice
No single method dominates. ARIA Analyst combines three: an HMM as the primary regime detector (producing probabilistic state inference), rolling-volatility cuts as a sanity-check feature, and a supervised classifier on macro features (providing leading information that the HMM cannot see). The three outputs are blended into a single regime probability vector that feeds the ML ensemble's routing layer.
The blending is straightforward: weighted average of the three probability vectors, with weights tuned on out-of-sample data. The HMM gets ~50% weight, macro classifier ~30%, rolling vol ~20% on most fits. The exact weights are less important than the diversity, using three signals provides robustness to any single method failing.
Common pitfalls
- Look-ahead in regime labels. If you label regimes ex-post and train a classifier on those labels, the labels themselves leak future information. Always use rolling labeling.
- Overfitting K. Higher K always fits training data better. Validate on held-out data.
- Treating regime probabilities as state labels. Probabilistic regime detection is more useful than binary classification. Argmax destroys information.
- Ignoring regime persistence. The transition probabilities matter as much as the per-state means. A regime that flips every 5 days is not a useful trading signal.
- Forgetting to handle the start of the series. The first 1-2 years of any rolling regime detector are noisy because the rolling window is not full. Either warm up the model on a pre-sample period or discard the early-period outputs.
Conclusion
Regime detection is the difference between a strategy that works on average and a strategy that works in every reasonable market condition. There are five reasonable methods, rolling volatility, HMM, MS-GARCH, supervised macro classification, and changepoint detection, each with strengths and weaknesses. The best applications combine two or three to get a robust regime probability vector that feeds downstream strategy logic.
ARIA Analyst uses an HMM + macro classifier + volatility-cut ensemble as the routing layer for its 9-bundle ML system. Create a free account to see live regime probabilities, or read our HMM trading guide for the details. See also GARCH volatility forecasting for the volatility piece of the puzzle.
Frequently asked questions
Is regime detection necessary if I use a simple strategy?
Even a simple strategy benefits from regime awareness if the strategy has a known weakness in certain conditions. Trend-following loses money in sideways markets; mean-reversion loses money in trending markets; volatility selling blows up in crisis regimes. Adding even a crude regime filter (e.g., turn off mean-reversion when realized vol is in the top 20% historically) often improves Sharpe meaningfully without complicating the strategy itself.
How many regimes are in the US stock market?
Empirically, K = 2 (calm vs. turbulent) explains most of the predictability, K = 3 (bull / sideways / bear) is the next reasonable step. K ≥ 4 typically overfits. The choice depends on application: portfolio rebalancing might use K = 2; option pricing might use K = 3 with a separate volatility model; tactical asset allocation often uses K = 4 with explicit "expansion / late-cycle / recession / recovery" labels.
Can I use the VIX as a regime indicator?
VIX is a useful regime feature but not a complete regime detector on its own. High VIX correlates with bear-market regimes but does not predict them, it spikes after the regime has started. Use VIX as one feature among many in a supervised classifier, or as the regime feature in a volatility-cut detector. Do not use VIX alone as the regime signal for tactical trading; you will arrive late to every regime change.
Ready to put this into practice?
ARIA Analyst applies these methods on any stock, crypto, forex, commodity, or fund. Three free analyses per day on the free tier.