Chart Library logo
Regime TrackerMarket AnalysisTutorial

What Is a Market Regime Tracker? How Chart Library Identifies Historical Market Parallels

Chart Library Team··6 min read

What Is a Market Regime?

A market regime is the combination of direction and volatility that defines the current market environment. Think of it as the market's mood. At any given time, the market falls into one of four broad categories: bull/calm (steady grind higher, low VIX), bull/volatile (sharp rallies with big intraday swings), bear/calm (slow bleed lower, orderly selling), or bear/volatile (panic selling, high VIX, large daily ranges).

Each regime behaves differently. Strategies that work in a calm bull market — buying dips, holding breakouts — often fail in a volatile bear market. The same chart pattern can produce completely different outcomes depending on the regime it appears in. That's why knowing the current regime matters as much as knowing the pattern itself.

Most traders assess regime intuitively: 'the market feels choppy' or 'we're in a strong trend.' Chart Library's regime tracker replaces intuition with data by finding the historical periods that most closely resemble today's market conditions — and showing you what happened next.

How the Regime Tracker Works

The regime tracker uses the same embedding and similarity search technology that powers Chart Library's pattern search, but applied to broad market indices and sector ETFs instead of individual stocks.

Every trading day, the system takes the most recent 30 days of 2-hour (2H) bars for SPY, QQQ, and 11 S&P sector ETFs (XLK, XLF, XLE, XLV, XLI, XLP, XLU, XLB, XLC, XLRE, XLY). These bars are converted into 384-dimensional embedding vectors using the same v2 numerical embedding pipeline used for individual stocks — encoding price movement, volume patterns, volatility structure, and VWAP deviation.

The system then performs an L2 (Euclidean) distance search against every historical 30-day window in the database, finding the periods that most closely resemble the current market structure. Matches are deduplicated with a minimum 10-day gap to ensure you see genuinely distinct historical periods rather than overlapping windows from the same episode.

What the Regime Tracker Tells You

For each index and sector ETF, the tracker returns the top historical matches along with what happened after those similar periods. You get 1, 3, 5, and 10-day forward returns for each match, plus aggregate statistics: average return, win rate (percentage of matches that went higher), and maximum drawdown.

An AI-generated summary synthesizes the data into plain English. For example: 'SPY's current 30-day pattern most closely resembles late October 2023 and early February 2024 — both periods of consolidation after strong rallies. 8 of 10 matches saw positive 10-day returns with an average gain of +2.1%, though 2 matches experienced drawdowns exceeding 3% before recovering.'

The sector heatmap shows all 11 S&P sectors at a glance, color-coded by their historical match outcomes. This makes it easy to spot which sectors have favorable historical precedent and which ones are flashing caution.

Note:The regime tracker runs automatically every night after market close (10:05 PM UTC) and the results appear on the /regime page and in the daily email briefing.

How to Read the Regime Page

The regime page is organized into three sections. At the top, you'll find the SPY and QQQ regime cards — the two most important indices for understanding overall market conditions. Each card shows the current 30-day price trajectory, the top historical matches with their dates and similarity scores, and the forward return statistics.

Below the main indices is the sector heatmap. Each cell represents one sector ETF and is colored based on the average forward return from its historical matches. Green means historically similar conditions led to gains; red means they led to losses. The intensity of the color reflects the magnitude.

At the bottom, you can expand individual sector cards to see the same detailed view as SPY and QQQ — top matches, forward returns, and AI summaries. This is useful for sector rotation analysis: if XLE (Energy) shows strong historical precedent while XLK (Tech) shows weak precedent, that's a signal worth investigating.

Example: Reading a Regime Snapshot

Suppose the regime tracker shows that SPY's current 30-day pattern most closely matches periods from August 2024, January 2025, and November 2023. All three were consolidation periods following a strong rally. The forward returns show 7 of 10 matches gained over the next 10 days, with an average return of +1.8%.

Meanwhile, the sector heatmap shows XLK and XLC (Communication Services) bright green, while XLE and XLU (Utilities) are neutral. This suggests that in historically similar environments, growth sectors outperformed defensive sectors — consistent with a risk-on continuation.

You wouldn't trade on this alone, but it's a useful data point. If your technical analysis says to buy a tech stock and the regime tracker confirms that similar macro environments favored tech, that's convergence. If the regime tracker shows the opposite, it's worth pausing to understand why.

Tip:Compare the regime tracker's view with individual stock pattern searches. When both the macro regime and the stock's specific pattern point in the same direction, historical win rates tend to be higher.

Why Regime Context Matters for Trading

Pattern similarity without regime context is like reading a weather forecast without knowing the season. A specific cloud formation means something different in July than in January. Similarly, a bull flag on AAPL means something different when the overall market is in a calm uptrend versus a volatile correction.

The regime tracker helps answer the question that pattern search alone cannot: 'Is the broader environment favorable for this type of setup?' By combining stock-level pattern intelligence with market-level regime data, you get a more complete picture of what history suggests — and a better sense of how much confidence to place in any individual pattern match.

Visit the /regime page to see today's regime snapshot, or check the daily email briefing for a summary delivered to your inbox every morning.

Check the current market regime at chartlibrary.io/regime — updated daily after market close.

Ready to try Chart Library?

Upload a chart screenshot or search any ticker — see what history says about your pattern.

Try it free