When a bar is at least 0.9 times as wide as the 72-bar average daily range, the system follows its direction: long on an up bar, short on a down bar. It takes profit at 1.9 times the average daily range or leaves after 9 bars. An opposite signal flips the position.
Best run of 23. DAX 40, 1 hour, spread 3, from run pf:2026-09-24-DAX40-1h.tsv:2.
| Period | Up to 2026-09-25 |
| Instrument | DAX 40, 1 hour |
| Spread | 3 points |
| Contracts | 1 |
| Starting capital | 1,000,000 |
| Costs | Spread only. Commissions and overnight financing are not included. |
| Bars | Up to 200,000 bars, fewer where the instrument has less history |
| Last tested | 2026-09-25 |
| positionSize Size per point | 1 |
| rangePeriod Bars in the average of the previous day's range | 72 |
| atrPeriod ATR length (1 is the bar's own true range) | 1 |
| volatilityFactor Share of the average daily range a bar must reach | 0.9 |
| targetFactor Target as a multiple of the average daily range | 1.9 |
| maxBarsInTrade Time exit after this many bars | 9 |
Every run
| Market | Timeframe | PF | Trades | Win % | Net | Max DD |
|---|---|---|---|---|---|---|
| DAX 40Best run | 1 hour | 1.39 | 475 | 50.74 | 6,346 EUR | -1,049 |
| Dow Jones | 1 hour | n/a | 174 | 55.17 | 5,386 EUR | -1,917 |
| Silver | 10 min | n/a | 113 | 42.48 | 2,862 USD | -1,813 |
| Brent Crude | 30 min | n/a | 163 | 47.85 | 2,437 EUR | -1,330 |
| Dow Jones | 15 min | n/a | 89 | 46.07 | 2,231 EUR | -1,223 |
| Dow Jones | 10 min | n/a | 74 | 50.00 | 2,177 EUR | -832 |
| DAX 40 | 30 min | n/a | 327 | 47.09 | 1,738 EUR | -1,161 |
| US Crude Oil | 15 min | n/a | 151 | 45.70 | 1,457 EUR | -665 |
| Silver | 5 min | n/a | 52 | 38.46 | 1,391 USD | -1,040 |
| Silver | 2 min | n/a | 2 | 100.00 | 1,027 USD | -259 |
| FTSE 100 | 30 min | n/a | 220 | 42.73 | 978 EUR | -792 |
| Nikkei 225 | 3 min | n/a | 15 | 66.67 | 945 USD | -540 |
| Silver | 3 min | n/a | 3 | 66.67 | 859 USD | -482 |
| DAX 40 | 5 min | n/a | 146 | 39.04 | 707 EUR | -610 |
| Nasdaq 100 | 3 min | n/a | 20 | 55.00 | 623 EUR | -409 |
| Nikkei 225 | 2 min | n/a | 7 | 57.14 | 600 USD | -415 |
| S&P 500 | 15 min | n/a | 128 | 50.78 | 588 EUR | -193 |
| DAX 40 | 10 min | n/a | 135 | 44.44 | 556 EUR | -378 |
| Dow Jones | 2 min | n/a | 10 | 30.00 | 452 EUR | -346 |
| Gold | 3 min | n/a | 9 | 55.56 | 97.10 EUR | -43.40 |
| S&P 500 | 2 min | n/a | 13 | 53.85 | 94.96 EUR | -47.31 |
| S&P 500 | 1 min | n/a | 7 | 57.14 | 76.58 EUR | -64.92 |
| Gold | 1 min | n/a | 2 | 100.00 | 22.30 EUR | -14.60 |
Charts
The code
Every file in the library uses the same header, the same section order and the same variable names. The numbers above were produced by the original version before the rewrite, and the rewrite has not yet been compiled in ProRealTime.
// ============================================================ // Volatility Breakout // ProRealAlgos Strategy Library | prorealalgos.com // Type: Volatility // Direction: Long & short // Timeframe tested: 1 hour // ============================================================ // --- Settings --- DEFPARAM CumulateOrders = false // --- Parameters --- positionSize = 1 // size per point rangePeriod = 72 // bars in the average of the daily range atrPeriod = 1 // ATR length, 1 = this bar's true range volatilityFactor = 0.9 // bar range must reach this share of the average daily range targetFactor = 1.9 // target as a multiple of the average daily range maxBarsInTrade = 9 // time exit after this many bars // --- Indicators --- // On Monday use the range from two days back, since Sunday has no real range. IF OpenDayOfWeek = 1 THEN dayRange = DHigh(2) - DLow(2) ELSE dayRange = DHigh(1) - DLow(1) ENDIF avgDayRange = Average[rangePeriod](dayRange) atrValue = AverageTrueRange[atrPeriod](close) targetDistance = avgDayRange * targetFactor wideBar = atrValue >= volatilityFactor * avgDayRange barsInTrade = BarIndex - TradeIndex
28 more lines: the entry and exit rules.
Read this first
Questions
Yes, it runs unattended and sizes in per point units. Check the target distance on your instrument first, because of how the points conversion works.
DAX 40 1 hour was the headline run with 6,346.40 EUR over 475 trades. All 22 other runs in the table were positive, including Dow Jones 1 hour at 5,386.40 EUR and Silver 10 minutes at 2,861.50 USD.
The DAX 40 1 hour run had a max drawdown of 1,049.20 EUR at 1 contract with a 3 point spread.
The entry compares one bar to a whole day of range. On 1 hour bars that happens often enough for 475 trades while still filtering small moves.
Related
The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.