Smooths the close with nested weighted moving averages and tracks the percentage change over 3 bars. It buys when that change exceeds 0.010472018% and sells when it falls below -0.010472018%.
Best run of 9. DAX 40, 1 hour, spread 3, from run sweeps:2026-10-12-DAX40-1h-opt.tsv:20.
| Period | Up to 2026-10-12 |
| Instrument | DAX 40, 1 hour |
| Spread | 3 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 |
|---|---|---|---|---|---|---|
| DAX 40Best run | 1 hour | n/a | 4,333 | 39.58 | 9,909 EUR | -3,738 |
| USD/JPY | Daily | n/a | 548 | 41.24 | 620,350 USD | -520,600 |
| Nikkei 225 | Daily | n/a | 479 | 43.01 | 34,376 USD | -15,429 |
| Dow Jones | Daily | n/a | 618 | 40.78 | 21,571 EUR | -6,218 |
| Dow Jones | 1 hour | n/a | 1,553 | 40.57 | 13,617 EUR | -9,304 |
| Nasdaq 100 | Daily | n/a | 464 | 40.30 | 9,999 EUR | -5,832 |
| DAX 40 | Daily | n/a | 631 | 41.36 | 8,309 EUR | -5,066 |
| Gold | Daily | n/a | 565 | 40.71 | 2,935 EUR | -1,047 |
| Gold | 4 hours | n/a | 1,294 | 40.88 | 2,255 EUR | -941 |
Charts
The code
// ============================================================== // Nested WMA Angle Trend Long // ProRealAlgos Strategy Library | prorealalgos.com // Type: Trend // Direction: Long only // Timeframe tested: 1 hour // ============================================================== DEFPARAM CumulateOrders = false mc = WeightedAverage[2](close) myMd = WeightedAverage[3](mc) me = WeightedAverage[5](myMd) mavw = WeightedAverage[8](me) prev = mavw[3] chg = 0
13 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 9 market and timeframe combinations. The best run by trade count was DAX 40, 1 hour, with 4,333 trades.
The best run had a maximum drawdown of 3,738 EUR at the tested position size, against a net result of 9,909 EUR.
It only takes long trades.
Related
The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.