The system buys when a momentum histogram first turns rising above zero, and sells short when it first turns falling below zero. Longs close when it stops rising above zero, and shorts close when it stops falling below zero.
Best run of 4. Gold, 4 hours, spread 0.6, from run sweeps:2026-10-12-GOLD-4h-opt.tsv:22.
| Period | Up to 2026-10-12 |
| Instrument | Gold, 4 hours |
| Spread | 0.6 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 |
|---|---|---|---|---|---|---|
| GoldBest run | 4 hours | n/a | 4,455 | 34.01 | 1,821 EUR | -1,572 |
| USD/JPY | Daily | n/a | 2,072 | 37.84 | 1,385,790 USD | -426,800 |
| GBP/USD | Daily | n/a | 2,070 | 38.02 | 14,851 USD | -4,376 |
| DAX 40 | 4 hours | n/a | 4,306 | 36.67 | 7,773 EUR | -3,546 |
Charts
The code
// ============================================================== // PMO Color State Signals // ProRealAlgos Strategy Library | prorealalgos.com // Type: Momentum // Direction: Long & short // Timeframe tested: 4 hours // ============================================================== DEFPARAM CumulateOrders = false ONCE csfa = 0 ONCE csfb = 0 ONCE hc = 0 chg = 100
45 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 4 market and timeframe combinations. The best run by trade count was Gold, 4 hours, with 4,455 trades.
The best run had a maximum drawdown of 1,572 EUR at the tested position size, against a net result of 1,821 EUR.
It trades both long and short.
Related
The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.