When price is below its 200 SMA and posts three higher closes in a row, the system sells short into the bounce. It covers as soon as a close drops below the 5 SMA.
Best run of 8. EUR/USD, 4 hours, spread 1, from run pf:2026-09-24-EURUSD-4h.tsv:1.
| Period | Up to 2026-09-25 |
| Instrument | EUR/USD, 4 hours |
| Spread | 1 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 Contracts per trade | 1 |
| trendPeriod Short only below this moving average | 200 |
| exitPeriod Cover when price closes below this moving average | 5 |
Every run
| Market | Timeframe | PF | Trades | Win % | Net | Max DD |
|---|---|---|---|---|---|---|
| EUR/USDBest run | 4 hours | 1.33 | 1,130 | 66.46 | 52,485 USD | -8,260 |
| EUR/USD | 1 hour | 1.08 | 4,272 | 64.91 | 25,321 USD | -34,246 |
| USD/JPY | Daily | n/a | 350 | 66.29 | 344,360 JPY | -213,700 |
| GBP/USD | Daily | n/a | 338 | 65.09 | 6,604 USD | -1,676 |
| GBP/USD | 4 hours | n/a | 1,106 | 67.54 | 3,642 USD | -1,461 |
| DAX 40 | Daily | n/a | 278 | 55.40 | 3,475 EUR | -2,140 |
| US Crude Oil | Daily | n/a | 258 | 62.40 | 2,317 EUR | -2,106 |
| FTSE 100 | Daily | n/a | 203 | 62.07 | 1,946 EUR | -1,069 |
Charts
Above 1.0 made money, below 1.0 lost money.
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.
// ============================================================ // Winning Market Declines // ProRealAlgos Strategy Library | prorealalgos.com // Type: Mean reversion // Direction: Short only // Timeframe tested: 4 hours // ============================================================ // --- Settings --- DEFPARAM CumulateOrders = false // --- Parameters --- positionSize = 1 // contracts per trade trendPeriod = 200 // short only below this moving average exitPeriod = 5 // cover when price closes below this moving average // --- Indicators --- trendMA = Average[trendPeriod](close) exitMA = Average[exitPeriod](close) threeHigherCloses = close > close[1] AND close[1] > close[2] AND close[2] > close[3]
14 more lines: the entry and exit rules.
Read this first
Questions
Yes, it is a short only system with 1 contract per trade. The rewritten code has not been compile checked.
All 7 other runs were profitable. GBP/USD Daily made USD 6,604.20 and DAX 40 Daily EUR 3,475.30.
On EUR/USD 4 hours the maximum drawdown was USD 8,260.00 against USD 52,485.00 net profit.
It gives more setups than daily bars while filtering out much of the 1 hour noise. The 4 hour run had a better profit factor than the 1 hour run.
Related
The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.