Strategies / S21
Donchian Breakout 20
Buy a new 20-bar high, sell a new 10-bar low.
Results
| Market class | Return | Holding | Sharpe | Max DD | Win rate | Trades |
|---|---|---|---|---|---|---|
| Crypto, 1d | +157% | +602% | 0.56 | -57.6% | 38.2% | 644 |
| Stocks, 1d | +1,527% | +28K% | 0.98 | -22.9% | 44.3% | 1,018 |
| Forex, 1d | +6.1% | +3.1% | 0.08 | -12.0% | 40.5% | 430 |
| Commodities, 1d | +126% | +1,833% | 0.31 | -24.8% | 40.0% | 578 |
| Indices, 1d | +184% | +878% | 0.54 | -20.0% | 44.4% | 599 |
The exact rule
- Go long when close is above the 20-bar high.
- Exit the long when close is below the 10-bar low.
- Declared timeframe: 1d.
Explain it with Ask AI (Premium, on a desktop)
Watch it trade
This runs the same engine in your browser on the latest candles, with your own costs. Press Replay to watch every entry and exit arrive bar by bar.
Download
Pine ScriptFor TradingView
Paper botRuns on the Bot API, no real money
Python backtestOne file, no dependencies
READMEThe rule in plain words
Want it to run by itself? Read the automate guide, and use paper money first.
Related strategies
Bollinger BreakoutBuy a close above the upper band, exit at the mid-line.Keltner BreakoutBuy a close above the Keltner channel, exit at its mid-line.Volume BreakoutA 20-bar high on twice the normal volume.
Research, not advice. Past results do not predict future ones. Results run to 2026-10-31.