The strategy buys when close moves above the upper 120-bar Bollinger Band and sells short below the lower band. Longs exit when close falls below the 110-bar SMA, shorts when it rises above, and each trade has a 6% stop loss.
Best run of 18. USD/JPY, Daily, spread 1, from run pf:2026-10-12-USDJPY-D.tsv:52.
| Period | Up to 2026-10-12 |
| Instrument | USD/JPY, Daily |
| Spread | 1 points |
| 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-10-12 |
Every run
| Market | Timeframe | PF | Trades | Win % | Net | Max DD |
|---|---|---|---|---|---|---|
| USD/JPYBest run | Daily | 2.21 | 101 | 48.51 | 2,330,220 USD | -459,100 |
| EUR/USD | Daily | 1.95 | 100 | 45.00 | 132,390 USD | -32,840 |
| USD/JPY | 10 min | n/a | 1,684 | 35.04 | 535,900 USD | -160,940 |
| USD/JPY | 30 min | n/a | 1,628 | 35.01 | 491,630 USD | -229,820 |
| USD/JPY | 15 min | n/a | 1,641 | 34.25 | 429,720 USD | -239,870 |
| Nikkei 225 | Daily | n/a | 91 | 42.86 | 34,765 USD | -14,037 |
| Silver | 30 min | n/a | 1,644 | 32.18 | 33,365 USD | -15,697 |
| Nikkei 225 | 2 min | n/a | 1,766 | 31.65 | 19,132 USD | -6,775 |
| Nikkei 225 | 1 hour | n/a | 786 | 35.50 | 13,001 USD | -9,252 |
| GBP/USD | Daily | n/a | 109 | 33.94 | 9,165 USD | -4,737 |
| Brent Crude | 30 min | n/a | 1,052 | 35.08 | 6,188 EUR | -5,098 |
| Gold | 30 min | n/a | 1,602 | 38.64 | 3,226 EUR | -851 |
| Gold | Daily | n/a | 101 | 42.57 | 2,479 EUR | -1,033 |
| Gold | 1 hour | n/a | 922 | 37.85 | 2,419 EUR | -846 |
| Gold | 10 min | n/a | 1,802 | 30.91 | 1,384 EUR | -878 |
| Gold | 5 min | n/a | 1,780 | 30.90 | 1,337 EUR | -579 |
| Gold | 3 min | n/a | 1,755 | 32.54 | 1,325 EUR | -689 |
| Gold | 15 min | n/a | 1,671 | 33.45 | 1,236 EUR | -660 |
Charts
Top 10 of 18 runs. The full list is in the table above.
Above 1.0 made money, below 1.0 lost money.
The code
// ============================================================== // Bollinger 120 Breakout With SMA Exit // ProRealAlgos Strategy Library | prorealalgos.com // Type: Breakout // Direction: Long & short // Timeframe tested: Daily // ============================================================== DEFPARAM CumulateOrders = false basis = Average[120](close) dev = 2 * STD[120](close) upper = basis + dev lower = basis - dev smaexit = Average[110](close)
19 more lines: the entry and exit rules.
Setup
Questions
Yes. The code is ProBuilder and runs as an automated ProOrder system. Backtest it on your own account with your own spread and position size before trading it live.
It was tested on 18 market and timeframe combinations. The best run was USD/JPY, Daily, with a profit factor of 2.21 over 101 trades.
The best run had a maximum drawdown of 459,100 USD at the tested position size, against a net result of 2,330,220 USD.
It trades both long and short.
Related
The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.