TRADERRYTraderry home

Canonical tearsheet

SPY Low-ADX Mean Reversion

SPY · 4h · 36 trades

Verified Out-of-Sample EdgeDSR 99.0%Fee floor 2.5 bps

In-sample Sharpe

0.93

Out-of-sample Sharpe

3.48

Your Executable Strategy Deliverables

Export to TradingView PineScript v5, Python Bot, or Live Cloud Webhook

Every strategy you build or clone compiles immediately into ready-to-paste TradingView PineScript v5 code, a standalone Python execution bot (`ccxt`), or a 24/7 cloud webhook protected by the Prop-Firm Risk Guardian.

// Paste directly into TradingView -> Pine Editor -> "Add to chart" (SPY · 4h)

// This Pine Script™ v5 strategy was auto-generated by Traderry.com Quant Foundry
// Strategy: SPY Low-ADX Mean Reversion
// Instrument: SPY · Timeframe: 4h · Direction: long_only
// Canonical Verification Hash: 43634a7abc57226bd04547cf293b1b73318b31377f3d4c7c447507c6b96596ea
//@version=5
strategy("SPY Low-ADX Mean Reversion [Traderry]", overlay=true, initial_capital=10000, default_qty_type=strategy.percent_of_equity, default_qty_value=55, commission_type=strategy.commission.percent, commission_value=0.05)

// --- 1. Risk & Execution Inputs ---
stopAtrMult   = input.float(2.8, "Stop-Loss ATR Multiplier", minval=0.25, maxval=10.0, step=0.1)
targetAtrMult = input.float(4.5, "Take-Profit ATR Multiplier", minval=0.25, maxval=20.0, step=0.1)
cooldownBars  = input.int(1, "Cooldown Bars After Exit", minval=0, maxval=50)

// --- 2. Strictly Causal Indicator Engine ---
rsi_14 = ta.rsi(close, 14)
ema_14 = ta.ema(close, 14)
atr_14 = ta.atr(14)

// --- 3. Signal Conditions (Evaluated on Bar Close) ---
longEntryCond  = (rsi_14 < 48)
longExitCond   = (rsi_14 > 58) or (close > ema_14)
shortEntryCond = false
shortExitCond  = false

var int lastExitBar = -999
canEnter = (bar_index - lastExitBar) >= cooldownBars and strategy.position_size == 0

// --- 4. Execution & ATR Volatility Stops ---
if canEnter and longEntryCond
    stopPrice   = close - (atr_14 * stopAtrMult)
    targetPrice = close + (atr_14 * targetAtrMult)
    strategy.entry("Long", strategy.long, alert_message='{"strategy_hash":"43634a7abc57226b","symbol":"SPY","side":"LONG","timeframe":"4h"}')
    strategy.exit("Long SL/TP", from_entry="Long", stop=stopPrice, limit=targetPrice)

if canEnter and shortEntryCond
    stopPrice   = close + (atr_14 * stopAtrMult)
    targetPrice = close - (atr_14 * targetAtrMult)
    strategy.entry("Short", strategy.short, alert_message='{"strategy_hash":"43634a7abc57226b","symbol":"SPY","side":"SHORT","timeframe":"4h"}')
    strategy.exit("Short SL/TP", from_entry="Short", stop=stopPrice, limit=targetPrice)

if strategy.position_size > 0 and longExitCond
    strategy.close("Long", comment="Signal Exit")
    lastExitBar := bar_index

if strategy.position_size < 0 and shortExitCond
    strategy.close("Short", comment="Signal Exit")
    lastExitBar := bar_index
In-sample versus Out-of-Sample Validation metrics
MetricIn-sample 75%Out-of-sample 25%Delta
Net return+8.51%+10.16%+1.65%
CAGR+61.13%+445.16%+384.03%
Sharpe0.9333.4792.546
Sortino0.7435.1264.383
Calmar9.91199.00089.089
Max drawdown-6.17%-1.25%+4.92%
Win rate+84.00%+100.00%+16.00%
Profit factor1.9769.9908.014
Trades2511-14
Avg trade+0.34%+0.88%+0.54%
Exposure+29.60%+35.20%+5.60%

Normalized equity ($10,000 base)

Real mark-to-market strategy equity versus buy-and-hold benchmark.

250 pts · 75/25 IS/OOS

25% Out-of-Sample Validation$11954$95552026-11-09DRAWDOWN-6.1%2025-09-192026-11-09● Equity ┄ Benchmark

Monte Carlo fan

p5 / p50 / p95 terminal paths. Historical resampling, not a forecast.

1,000 paths

22.9%-2.7%step 0step 24

p95 max DD

0.00%

Prop-Firm Pass Probability

Ruin risk 0.50%

p5
+1.3%
p50
+12.8%
p95
+22.9%

Regime

Bull Trend

+2.04%

Sharpe
2.59
Win rate
+100.0%
Bar share
+15.0%

Regime

Bear Market

-4.77%

Sharpe
-3.82
Win rate
+100.0%
Bar share
+6.6%

Regime

Macro Volatility

+6.91%

Sharpe
1.15
Win rate
+66.7%
Bar share
+28.2%

Regime

Range / Chop

+14.20%

Sharpe
2.78
Win rate
+94.7%
Bar share
+50.2%

Rules in plain structure

Long entry · rsi_14 LT 48
Long exit · rsi_14 GT 58 OR close GT ema_14
Short entry · None
Short exit · None

43634a7abc57226bd04547cf293b1b73318b31377f3d4c7c447507c6b96596ea

Mathematical critique

Traderry Quant Audit Engine

VERIFIED structure with disciplined Out-of-Sample Validation.

Statistical weaknesses

  • None material under current sample

Regime vulnerabilities

  • HIGH_VOL_MACRO whipsaw
  • BEAR_DRAWDOWN drift

Parameter notes

  • Tighten stop_loss_atr_mult by 0.25
  • Increase cooldown_bars by 1
Clone & Customize in Foundry
Autonomous Desk Intelligence Briefing

Get the Daily Out-of-Sample Ledger & Macro Lockout Alerts.

Receive automated post-mortems when House Agents close high-conviction positions, weekly newly verified Out-of-Sample tearsheets, and 15-minute pre-release CPI/FOMC risk lockout warnings via email or instant Discord/Telegram webhook.

Zero spam. Instant 1-click unsubscribe. Non-custodial quantitative research only.