The strategy buys short-term dips in an uptrend, when a 2-period RSI falls below 5 and then recovers. It sells short rallies in a downtrend, when the RSI rises above 95, and exits when price moves back across the 10-period average.
Best run of 8. EUR/USD, 4 hours, spread 1, from run sweeps:2026-10-11-EURUSD-4h-opt.tsv:7.
| Period | Up to 2026-10-11 |
| Instrument | EUR/USD, 4 hours |
| 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-11 |
Every run
| Market | Timeframe | PF | Trades | Win % | Net | Max DD |
|---|---|---|---|---|---|---|
| EUR/USDBest run | 4 hours | n/a | 942 | 67.73 | 46,241 USD | -15,559 |
| EUR/USD | Daily | n/a | 250 | 72.40 | 45,445 USD | -18,441 |
| Nikkei 225 | Daily | n/a | 217 | 65.90 | 10,096 USD | -9,565 |
| Dow Jones | Daily | n/a | 313 | 65.81 | 8,583 EUR | -3,297 |
| Nikkei 225 | 4 hours | n/a | 526 | 66.73 | 8,252 USD | -6,661 |
| Nasdaq 100 | 4 hours | n/a | 696 | 62.93 | 3,408 EUR | -2,329 |
| S&P 500 | Daily | n/a | 338 | 63.61 | 1,504 EUR | -687 |
| Gold | Daily | n/a | 275 | 66.55 | 356 EUR | -352 |
Charts
The code
// ============================================================== // RSI Pullback With Trend Filter (long and short) // ProRealAlgos Strategy Library | prorealalgos.com // Type: Mean reversion // Direction: Long & short // Timeframe tested: 4 hours // ============================================================== DEFPARAM CumulateOrders = false maexit = Average[10](close) matrend = Average[200](close) myRsi = RSI[2](close)
21 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 8 market and timeframe combinations. The best run by trade count was EUR/USD, 4 hours, with 942 trades.
The best run had a maximum drawdown of 15,559 USD at the tested position size, against a net result of 46,241 USD.
It trades both long and short.
Related
The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.