STRASMORE/EXPLORE 2,595 QUERIES

drawdown_episodes

Answered against 22 years of US equities and 12 years of US options data and published with the query that produced it. This result is stored as of 2026-09-25, from msft-decline-from-peak.

as of table 11×5read in context →
drawdown_episodes — 11 rows by 5 columns, computed from US exchange, SIP and OPRA data.
peak_ontrough_ondepth_pctsessions_below_peakdays_to_recover
2021/11/192022/11/0337.6392573
2025/10/282026/06/2534.92280
2020/02/102020/03/1628.282120
2024/07/052025/04/0824.2229335
2018/10/012018/12/2418.6112165
2015/04/282015/08/2517.7124178
2015/01/082015/04/0215.372106
2015/12/292016/06/2714.4141206
2020/09/022020/09/1813.598146
2023/07/182023/09/2613.278112
2018/01/312018/02/0810.51626
Rows × columns
11 × 5
Computed
Completeness
No missing values
Source
US exchange, SIP and OPRA market data
Licence
Strasmore terms · free, no signup
Formats
JSON · CSV · the SQL below

What each column holds

Column definitions for drawdown_episodes, derived from the stored result.
ColumnTypeRangeNotes
peak_on text 11 distinct values (2015/01/08, 2015/04/28, 2015/12/29…)
trough_on text 11 distinct values (2015/04/02, 2015/08/25, 2016/06/27…)
depth_pct number 10.5 to 37.6 percent
sessions_below_peak number 16 to 392
days_to_recover number 0 to 573

Computed from Strasmore's warehouse of US exchange, SIP and OPRA market data. Equity prices are delayed; options greeks and implied volatility are end-of-day. This result is stored, not recomputed on load — it is exactly the numbers that were returned on , and the query below is what returned them.

Run it yourself

This is the exact query behind the result above. Change a ticker, a date or a column and run it against the warehouse — no account, no key. The no-signup tier is smaller than the one this page was computed on; a query that reaches past it comes back saying which plan runs it.

WITH daily AS
(
    SELECT
        date,
        toFloat64(max(close)) AS close
    FROM global_markets.stocks_daily_aggs
    WHERE ticker = 'MSFT'
      AND date >= '2015-01-01'
    GROUP BY date
),
marked AS
(
    SELECT
        date,
        close,
        max(close)          OVER (ORDER BY date ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) AS peak_close,
        argMax(date, close) OVER (ORDER BY date ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW) AS peak_date
    FROM daily
),
next_session AS
(
    SELECT
        date,
        any(date) OVER (ORDER BY date ROWS BETWEEN 1 FOLLOWING AND 1 FOLLOWING) AS next_date
    FROM daily
),
episodes AS
(
    SELECT
        peak_date,
        any(peak_close)     AS peak_level,
        min(close)          AS trough_level,
        argMin(date, close) AS trough_date,
        max(date)           AS last_below_date,
        count()             AS sessions_below
    FROM marked
    WHERE close < peak_close
    GROUP BY peak_date
    HAVING min(close) / any(peak_close) <= 0.90
)
SELECT
    formatDateTime(e.peak_date, '%Y/%m/%d')             AS peak_on,
    formatDateTime(e.trough_date, '%Y/%m/%d')           AS trough_on,
    round((1 - e.trough_level / e.peak_level) * 100, 1) AS depth_pct,
    toUInt32(e.sessions_below)                          AS sessions_below_peak,
    if(n.next_date > e.peak_date,
       toUInt32(dateDiff('day', e.peak_date, n.next_date)),
       toUInt32(0))                                     AS days_to_recover
FROM episodes AS e
LEFT JOIN next_session AS n ON n.date = e.last_below_date
ORDER BY depth_pct DESC
⌘/Ctrl + Enter

在你的 AI 助理中使用這些資料

開啟即可查詢,已帶入本頁資料。免費,無需帳號。