PriceMomentum_V0771
ARCHIVEDhybridllmSimplified and regularized entry momentum rule (ret_20d > 3%) with a clear trend/MA gate (close > sma_50 OR positive sma_50_slope), added a volatility percentile filter and looser long-term drawdown guard to reduce overfitting. Expanded exit to faster, multi-condition rules (5d stop, 20d stop, or MA break) for better risk control. Added regime gates to only trade in uptrends and non-high-volatility regimes, and tiered position sizing by volatility (full size in low vol, reduced in medium/high) to lower drawdowns and improve walk-forward robustness.
Lineage
logic of PriceMomentum_V0539 with risk overlay of LongTermTrend_V0472
Strategy Logic (pseudocode)
# PriceMomentum_V0771 [hybrid]
require regime.trend in ['UPTREND']
require regime.volatility in ['LOW_VOLATILITY', 'MEDIUM_VOLATILITY']
require regime.bubble in ['NORMAL', 'EXPENSIVE']
if flat and (ret_20d > 0.03 and (close > sma_50 or sma_50_slope > 0.0) and vol_pctile < 0.85 and cumret_252d > -0.5):
position = 1.0
if long and (ret_5d < -0.05 or close < sma_50 or ret_20d < -0.03):
position = 0.0 # exit to cash
if regime.volatility == "LOW_VOLATILITY": position *= 1.0
if regime.volatility == "MEDIUM_VOLATILITY": position *= 0.7
if regime.volatility == "HIGH_VOLATILITY": position *= 0.35Backtest Metrics
| Metric | Train | Validation | Hidden Test | Full |
|---|---|---|---|---|
| CAGR | 3.6% | 16.6% | 3.8% | 6.4% |
| Total Return | 32.9% | 58.5% | 15.0% | 149.3% |
| Sharpe | 0.30 | 0.84 | 0.29 | 0.43 |
| Sortino | 0.19 | 0.64 | 0.15 | 0.28 |
| Calmar | 0.12 | 0.40 | 0.15 | 0.16 |
| Volatility | 16.8% | 20.7% | 19.1% | 18.2% |
| Max DD | -29.9% | -41.3% | -25.8% | -41.3% |
| Win Rate | 41.9% | 37.5% | 45.5% | 41.6% |
| Avg Win | 5.5% | 14.5% | 6.4% | 8.9% |
| Avg Loss | -3.5% | -4.4% | -3.7% | -3.8% |
| Payoff | 1.58 | 3.30 | 1.70 | 2.36 |
| Expectancy | 0.3% | 2.7% | 0.9% | 1.5% |
| Profit Factor | 1.14 | 1.98 | 1.42 | 1.68 |
| Trades | 43 | 24 | 22 | 89 |
| Avg Holding Days | 9.5 | 8.0 | 6.8 | 8.7 |
| Turnover | 9.9 | 13.0 | 11.0 | 10.8 |
| Exposure | 17.7% | 18.5% | 11.7% | 16.4% |
Growth of $100
Walk-Forward Years
| Year | CAGR | Sharpe | Max DD | Trades |
|---|---|---|---|---|
| 2016 | -4.4% | -0.52 | -9.1% | 3 |
| 2017 | 13.2% | 0.79 | -11.3% | 11 |
| 2018 | -14.7% | -1.35 | -14.6% | 3 |
| 2019 | 18.0% | 1.40 | -7.3% | 3 |
| 2020 | 66.4% | 2.58 | -7.9% | 6 |
| 2021 | 32.0% | 1.21 | -20.0% | 9 |
| 2022 | -29.8% | -2.44 | -31.5% | 9 |
A robust strategy performs acceptably in most years rather than spectacularly in one — look for consistency across regimes, not a single outlier year.
Regime Performance
| Period | Regime | Days | Ann. Return | Sharpe | Exposure |
|---|---|---|---|---|---|
| hidden test | DOWNTREND | 272 | 0.0% | 0.00 | 0% |
| hidden test | EXPENSIVE | 83 | 61.7% | 1.84 | 43% |
| hidden test | EXTREME | 48 | 0.0% | 0.00 | 0% |
| hidden test | HIGH VOLATILITY | 254 | -16.8% | -1.20 | 1% |
| hidden test | LOW VOLATILITY | 432 | 19.9% | 1.20 | 14% |
| hidden test | MEDIUM VOLATILITY | 250 | 3.5% | 0.13 | 18% |
| hidden test | NORMAL | 805 | 0.1% | 0.01 | 9% |
| hidden test | SIDEWAYS | 293 | -11.3% | -1.15 | 2% |
| hidden test | UPTREND | 371 | 23.0% | 0.79 | 28% |
| train | DOWNTREND | 518 | 0.0% | 0.00 | 0% |
| train | EXPENSIVE | 311 | 36.1% | 1.44 | 34% |
| train | EXTREME | 100 | 8.1% | 1.55 | 1% |
| train | HIGH VOLATILITY | 699 | 6.2% | 0.46 | 1% |
| train | LOW VOLATILITY | 745 | 22.2% | 1.11 | 38% |
| train | MEDIUM VOLATILITY | 568 | -19.3% | -1.24 | 12% |
| train | NORMAL | 1,601 | -1.3% | -0.09 | 16% |
| train | SIDEWAYS | 592 | -8.5% | -1.22 | 1% |
| train | UPTREND | 902 | 16.7% | 0.68 | 39% |
| validation | DOWNTREND | 125 | 0.0% | 0.00 | 0% |
| validation | EXPENSIVE | 138 | 77.7% | 2.62 | 38% |
| validation | EXTREME | 144 | 33.1% | 2.61 | 2% |
| validation | HIGH VOLATILITY | 258 | -5.7% | -0.66 | 1% |
| validation | LOW VOLATILITY | 183 | 7.2% | 0.35 | 38% |
| validation | MEDIUM VOLATILITY | 315 | 42.4% | 1.58 | 22% |
| validation | NORMAL | 474 | -4.8% | -0.25 | 18% |
| validation | SIDEWAYS | 206 | -29.2% | -2.31 | 2% |
| validation | UPTREND | 425 | 45.2% | 1.73 | 32% |
Trades (full period)
| Entry | Exit | Entry Px | Exit Px | Return | Days | |
|---|---|---|---|---|---|---|
| 2026-05-29 | 2026-06-01 | $435.79 | $415.88 | -1.63% | 2 | |
| 2026-01-02 | 2026-01-05 | $438.07 | $451.67 | -2.79% | 2 | |
| 2025-12-12 | 2025-12-31 | $458.96 | $449.72 | 1.49% | 13 | |
| 2025-09-12 | 2025-11-10 | $395.94 | $445.23 | 13.53% | 42 | |
| 2025-09-04 | 2025-09-05 | $338.53 | $350.84 | 1.13% | 2 | |
| 2025-07-31 | 2025-08-01 | $308.27 | $302.63 | -2.50% | 2 | |
| 2025-07-08 | 2025-07-09 | $297.81 | $295.88 | 0.78% | 2 | |
| 2025-06-05 | 2025-06-06 | $284.70 | $295.14 | -10.11% | 2 | |
| 2025-05-22 | 2025-06-04 | $341.04 | $332.05 | 2.77% | 9 | |
| 2024-10-09 | 2024-10-14 | $241.05 | $219.16 | -11.10% | 4 | |
| 2024-10-07 | 2024-10-08 | $240.83 | $244.50 | -3.90% | 2 | |
| 2024-10-03 | 2024-10-04 | $240.66 | $250.08 | -2.49% | 2 | |
| 2024-09-23 | 2024-09-27 | $250.00 | $260.46 | 4.53% | 5 | |
| 2024-09-16 | 2024-09-20 | $226.78 | $238.25 | 4.02% | 5 | |
| 2024-09-05 | 2024-09-09 | $230.17 | $216.27 | -2.82% | 3 | |
| 2024-09-03 | 2024-09-04 | $210.60 | $219.41 | -1.29% | 2 | |
| 2024-07-02 | 2024-07-12 | $231.26 | $248.23 | 13.38% | 8 | |
| 2024-01-03 | 2024-01-04 | $238.45 | $237.93 | -4.21% | 2 | |
| 2023-07-27 | 2023-08-02 | $255.71 | $254.11 | -0.83% | 5 | |
| 2023-07-25 | 2023-07-26 | $265.28 | $264.35 | -1.12% | 2 | |
| 2023-06-28 | 2023-07-21 | $256.24 | $260.02 | 5.97% | 17 | |
| 2023-06-02 | 2023-06-27 | $213.97 | $250.21 | 15.93% | 17 | |
| 2022-09-20 | 2022-09-23 | $308.73 | $275.33 | -6.81% | 4 | |
| 2022-09-12 | 2022-09-14 | $304.42 | $302.61 | -2.71% | 3 | |
| 2022-08-16 | 2022-08-22 | $306.56 | $289.91 | -3.67% | 5 | |
| 2022-08-05 | 2022-08-08 | $288.17 | $290.42 | -4.78% | 2 | |
| 2022-04-19 | 2022-04-27 | $342.72 | $293.84 | -9.02% | 7 | |
| 2022-04-14 | 2022-04-18 | $328.33 | $334.76 | -2.70% | 2 | |
| 2022-04-12 | 2022-04-13 | $328.98 | $340.79 | 0.65% | 2 | |
| 2022-04-05 | 2022-04-11 | $363.75 | $325.31 | -7.53% | 5 | |
| 2022-01-12 | 2022-01-13 | $368.74 | $343.85 | 2.61% | 2 | |
| 2021-12-09 | 2021-12-10 | $334.60 | $339.01 | -4.40% | 2 | |
| 2021-11-23 | 2021-12-01 | $369.68 | $365.00 | -0.82% | 6 | |
| 2021-08-24 | 2021-11-10 | $236.16 | $355.98 | 45.15% | 56 | |
| 2021-08-19 | 2021-08-20 | $224.49 | $226.75 | -2.45% | 2 | |
| 2021-08-05 | 2021-08-18 | $238.21 | $229.66 | -6.55% | 10 | |
| 2021-02-02 | 2021-02-11 | $290.93 | $270.55 | -4.66% | 8 | |
| 2021-01-20 | 2021-02-01 | $283.48 | $279.94 | -4.34% | 9 | |
| 2021-01-12 | 2021-01-19 | $283.15 | $281.52 | 1.18% | 5 | |
| 2020-12-10 | 2021-01-11 | $209.02 | $270.40 | 30.32% | 21 | |
| 2020-11-19 | 2020-12-08 | $166.42 | $216.63 | 21.45% | 13 | |
| 2020-10-26 | 2020-10-29 | $140.09 | $136.94 | -3.67% | 4 | |
| 2020-10-22 | 2020-10-23 | $141.93 | $140.21 | 0.38% | 2 | |
| 2020-10-13 | 2020-10-20 | $148.88 | $140.65 | -1.93% | 6 | |
| 2020-06-25 | 2020-06-30 | $65.73 | $71.99 | 3.41% | 4 | |
| 2019-12-02 | 2020-01-22 | $22.32 | $37.97 | 63.58% | 35 | |
| 2019-11-27 | 2019-11-29 | $22.09 | $22.00 | 0.52% | 2 | |
| 2019-11-22 | 2019-11-25 | $22.20 | $22.42 | -6.33% | 2 | |
| 2019-10-21 | 2019-10-22 | $16.90 | $17.04 | -1.08% | 2 | |
| 2018-11-27 | 2018-12-19 | $22.93 | $22.20 | -1.14% | 16 | |
| 2018-02-08 | 2018-02-09 | $21.02 | $20.69 | -8.82% | 2 | |
| 2018-02-01 | 2018-02-06 | $23.28 | $22.26 | -5.27% | 4 | |
| 2017-10-05 | 2017-10-10 | $23.69 | $23.71 | -2.51% | 4 | |
| 2017-09-18 | 2017-09-25 | $25.67 | $23.00 | -6.74% | 6 | |
| 2017-08-15 | 2017-08-18 | $24.16 | $23.16 | -2.42% | 4 | |
| 2017-08-04 | 2017-08-07 | $23.79 | $23.68 | 1.84% | 2 | |
| 2017-06-30 | 2017-07-03 | $24.11 | $23.51 | 0.03% | 2 | |
| 2017-06-05 | 2017-06-14 | $23.15 | $25.38 | 6.94% | 8 | |
| 2017-05-12 | 2017-05-18 | $21.65 | $20.87 | -3.82% | 5 | |
| 2017-04-24 | 2017-05-10 | $20.54 | $21.68 | 1.07% | 13 | |
| 2017-04-20 | 2017-04-21 | $20.17 | $20.37 | -0.83% | 2 | |
| 2017-03-28 | 2017-04-04 | $18.50 | $20.25 | 7.92% | 6 | |
| 2017-01-05 | 2017-02-24 | $15.12 | $17.13 | 12.55% | 35 | |
| 2016-07-26 | 2016-08-23 | $15.30 | $14.99 | -3.27% | 21 | |
| 2016-06-08 | 2016-06-09 | $15.70 | $15.29 | 1.17% | 2 | |
| 2016-04-05 | 2016-05-02 | $17.03 | $16.12 | -2.33% | 20 | |
| 2015-08-06 | 2015-08-07 | $16.41 | $16.17 | -6.35% | 2 | |
| 2015-07-14 | 2015-07-28 | $17.71 | $17.65 | -0.41% | 11 | |
| 2015-05-11 | 2015-07-13 | $15.97 | $17.48 | 9.31% | 44 | |
| 2015-04-29 | 2015-05-01 | $15.50 | $15.07 | -2.12% | 3 | |
| 2014-09-19 | 2014-09-22 | $17.29 | $16.67 | -1.33% | 2 | |
| 2014-08-05 | 2014-09-16 | $15.90 | $17.38 | 6.22% | 30 | |
| 2014-07-11 | 2014-07-17 | $14.54 | $14.36 | -1.25% | 5 | |
| 2014-07-09 | 2014-07-10 | $14.87 | $14.63 | 1.62% | 2 | |
| 2014-06-23 | 2014-07-08 | $15.81 | $14.60 | -3.21% | 11 | |
| 2014-03-20 | 2014-03-25 | $15.66 | $14.70 | -4.81% | 4 | |
| 2014-02-13 | 2014-02-26 | $13.31 | $16.87 | 17.45% | 9 | |
| 2013-10-11 | 2013-10-22 | $11.91 | $11.44 | -2.02% | 8 | |
| 2013-10-09 | 2013-10-10 | $11.25 | $11.53 | -2.52% | 2 | |
| 2013-10-07 | 2013-10-08 | $12.20 | $11.65 | 0.67% | 2 | |
| 2013-09-09 | 2013-10-04 | $10.71 | $12.07 | 3.59% | 20 | |
| 2013-03-26 | 2013-04-02 | $2.52 | $2.96 | 16.82% | 5 | |
| 2013-02-20 | 2013-02-22 | $2.57 | $2.41 | -10.67% | 3 | |
| 2013-01-24 | 2013-02-19 | $2.47 | $2.62 | 2.69% | 18 | |
| 2012-12-18 | 2013-01-11 | $2.31 | $2.19 | -2.72% | 17 | |
| 2012-11-23 | 2012-12-14 | $2.14 | $2.25 | 3.30% | 16 | |
| 2012-04-09 | 2012-04-10 | $2.21 | $2.16 | -2.84% | 2 | |
| 2012-02-23 | 2012-04-05 | $2.30 | $2.30 | 4.71% | 31 | |
| 2012-02-21 | 2012-02-22 | $2.30 | $2.28 | -1.54% | 2 |