S&P 500 (SPY ETF) — 26 Classic Pine Script v5 Rules on Sealed Data
On S&P 500 (SPY ETF) (8,472 daily sessions from 1993-01-29 to 2026-09-25, sealed 20% window starting 2019-12-30), the strongest judgeable showing comes from EMA Crossover 9/21 (+98.49% — judge engine verdict, computed on S&P 500 (SPY): No proof yet (1/4 steps)) against +139.76% for passive holding. Test your own OHLCV CSV on this market directly in the free browser judge.
S&P 500 sealed window summary
Public daily bars from Yahoo Finance (SPY), files dated 2026-09-30 (last session: 2026-09-25), raw series not redistributed.
All 26 Pine v5 strategies on S&P 500 (sorted by out-of-sample hold vs Buy & Hold)
Unadjusted SPY closes (dividends excluded): benchmark Buy & Hold understates total-return holding by ~1.3 percentage points per year.
| Pine v5 Rule | Family | Sealed Return | Vs Buy & Hold | Ahead of Holding? | Judge engine verdict, computed on S&P 500 (SPY) | Sealed Trades | Replay |
|---|---|---|---|---|---|---|---|
| EMA Crossover 9/21 | Trend Following | +98.49% | -41.27 pts | No | No proof yet (1/4 steps) | 27 | Open in judge (on BTCUSDT) → |
| ALMA 20 Gaussian Trend | Trend Following | +92.08% | -47.68 pts | No | No proof yet (2/4 steps) | 20 | Open in judge (on BTCUSDT) → |
| Bollinger Band Bounce | Mean Reversion | +77.18% | -62.58 pts | No | No proof yet (2/4 steps) | 18 | Open in judge (on BTCUSDT) → |
| Donchian Turtle 20/10 | Volatility Breakout | +71.28% | -68.48 pts | No | No proof yet (1/4 steps) | 33 | Open in judge (on BTCUSDT) → |
| ATR 14 Chandelier Stop | Volatility Breakout | +67.14% | -72.62 pts | No | No proof yet (2/4 steps) | 28 | Open in judge (on BTCUSDT) → |
| Hull Moving Average 55 | Trend Following | +63.30% | -76.46 pts | No | No proof yet (1/4 steps) | 35 | Open in judge (on BTCUSDT) → |
| CCI 20 (+100) Breakout | Momentum & Volume | +50.90% | -88.86 pts | No | No proof yet (1/4 steps) | 49 | Open in judge (on BTCUSDT) → |
| EMA Ribbon 8/21/55 | Trend Following | +46.09% | -93.67 pts | No | No proof yet (1/4 steps) | 30 | Open in judge (on BTCUSDT) → |
| MACD Momentum | Momentum & Volume | +40.57% | -99.19 pts | No | No proof yet (1/4 steps) | 76 | Open in judge (on BTCUSDT) → |
| Linear Regression 20 | Trend Following | +40.03% | -99.73 pts | No | No proof yet (2/4 steps) | 22 | Open in judge (on BTCUSDT) → |
| Stochastic RSI | Mean Reversion | +39.00% | -100.76 pts | No | No proof yet (1/4 steps) | 33 | Open in judge (on BTCUSDT) → |
| Parabolic SAR 0.02/0.2 | Trend Following | +32.73% | -107.03 pts | No | No edge evidence (1/4) | 82 | Open in judge (on BTCUSDT) → |
| Pivot High/Low Breakout | Volatility Breakout | +23.41% | -116.35 pts | No | No proof yet (1/4 steps) | 23 | Open in judge (on BTCUSDT) → |
| ADX 25 & DMI 14 Trend | Trend Following | +21.27% | -118.49 pts | No | No proof yet (1/4 steps) | 27 | Open in judge (on BTCUSDT) → |
| Keltner Channel Breakout 20/1.5 | Volatility Breakout | +20.21% | -119.55 pts | No | No proof yet (1/4 steps) | 38 | Open in judge (on BTCUSDT) → |
| SuperTrend | Trend Following | +20.02% | -119.74 pts | No | No proof yet (1/4 steps) | 32 | Open in judge (on BTCUSDT) → |
| AI-style ATR Breakout + EMA 200 | Multi-Timeframe & AI | +18.64% | -121.12 pts | No | No proof yet (1/4 steps) | 39 | Open in judge (on BTCUSDT) → |
| ROC 14 + EMA 200 Filter | Momentum & Volume | +12.38% | -127.38 pts | No | No proof yet (1/4 steps) | 21 | Open in judge (on BTCUSDT) → |
| Williams %R 14 Pullback | Mean Reversion | +10.41% | -129.35 pts | No | No proof yet (1/4 steps) | 41 | Open in judge (on BTCUSDT) → |
| Ichimoku Tenkan 9 / Kijun 26 | Trend Following | +0.48% | -139.28 pts | No | No proof yet (1/4 steps) | 21 | Open in judge (on BTCUSDT) → |
| Bollinger Squeeze Breakout | Volatility Breakout | -5.58% | -145.34 pts | No | No edge evidence (1/4) | 29 | Open in judge (on BTCUSDT) → |
| No-Leak Weekly EMA Filter | Multi-Timeframe & AI | -15.15% | -154.91 pts | No | No edge evidence (1/4) | 95 | Open in judge (on BTCUSDT) → |
| VWAP Bounce | Momentum & Volume | -44.12% | -183.88 pts | No | No edge evidence (1/4) | 416 | Open in judge (on BTCUSDT) → |
| Golden Cross SMA 50/200 | Trend Following | +117.89% | -21.87 pts | Few trades (<10) | Not enough trades | 2 | Open in judge (on BTCUSDT) → |
| Money Flow Index MFI 14 (20/80) | Momentum & Volume | +100.63% | -39.13 pts | Few trades (<10) | Not enough trades | 6 | Open in judge (on BTCUSDT) → |
| RSI Mean Reversion | Mean Reversion | +48.41% | -91.35 pts | Few trades (<10) | Not enough trades | 6 | Open in judge (on BTCUSDT) → |
Test your own rule on S&P 500 (CSV candles or TradingView export)
You do not have to rely on Bitcoin alone to check a Pine v5 strategy before risking capital:
- In the free online judge (/en/strategy-judge), open “Another market than BTCUSDT? Test on your own candles (CSV file)” and drop your daily or intraday OHLCV CSV (read locally in your browser, never uploaded).
- In the free desktop Strategy Arena Lab (/en/download), replay your rule locally on multi-year histories with trial counting.
- If your Pine script uses constructs specific to TradingView or non-crypto symbols, export the Strategy Tester's “List of trades” CSV (available on TradingView Essential plans and above) into /en/dossier for a free preview (before/after cut date and fee impact).
Online judge & desktop Lab: €0. Full TradingView trade-list audit dossier: €9 one-time payment (or 1 credit; €9 / €25 / €49 credit packs), no account required, with a 7-day full refund guarantee if the dossier teaches you nothing beyond the free preview or the TradingView Strategy Tester.
Data sources, spectral diversity & related benchmarks
Public daily bars from Yahoo Finance (SPY), files dated 2026-09-30 (last session: 2026-09-25), raw series not redistributed. Unadjusted SPY closes (dividends excluded): benchmark Buy & Hold understates total-return holding by ~1.3 percentage points per year.
Effective market diversity (Ledoit & Wolf 2004 analytical shrinkage on the 2,247 common trading sessions across all 8 markets, with zero missing-day zero-filling): optimal shrinkage δ* = 0.0223, yielding 4.11 effective independent market bets out of 8 (4.02 before shrinkage).
- Bitcoin 3-Timeframe Benchmark (1D, 4H, 1H) — How timeframe granularity affects fee drag on BTCUSDT.
- 29 Free Pine Script v5 Strategy Sheets — Full source code, parameters and BTC verdicts for each rule.
- 17 Classic Market Rules Tested on Unseen Years — Out-of-sample protocol applied to literature rules.
Frequently asked questions
How were these 26 strategies tested on S&P 500?
Each Pine Script v5 rule was replayed without parameter tuning by the judge engine (judge engine verdict, computed on S&P 500 (SPY)) on the first 80% of daily bars (up to 2019-12-30) and evaluated once with fresh capital on the latest 20% (2019-12-30 → 2026-09-25) with 0.10% fee per fill.
How can I test my own S&P 500 strategy in Strategy Arena?
Prepare a standard OHLCV CSV file for S&P 500 from a data source you are licensed to use and drop it into the CSV zone of /en/strategy-judge, or export your Strategy Tester “List of trades” CSV from TradingView into /en/dossier.
Historical research on past market data, never investment advice or a promise of future returns. Pine Script® is a trademark of TradingView.