Double Sevens buys when price is above its 200 day SMA and the bar trades down to the lowest close of the last 7 bars. It sells once the high reaches the highest close of the last 7 bars. It trades long only and relies on short dips inside a longer uptrend.
Best run of 9. Nasdaq 100, Daily, spread 3, from run pf:2026-09-24-NAS100-D.tsv:2.
| Period | Up to 2026-09-24 |
| Instrument | Nasdaq 100, Daily |
| Spread | 3 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-24 |
| positionSize Contracts per trade | 1 |
| entryLookback Buy at a new low of the last closes over this many bars | 7 |
| exitLookback Sell at a new high of the last closes over this many bars | 7 |
| trendPeriod Long only above this moving average | 200 |
Every run
| Market | Timeframe | PF | Trades | Win % | Net | Max DD |
|---|---|---|---|---|---|---|
| Nasdaq 100Best run | Daily | 1.58 | 743 | 63.12 | 14,160 EUR | -2,786 |
| S&P 500 | Daily | 1.47 | 1,013 | 55.38 | 3,181 EUR | -621 |
| EUR/USD | 3 min | 1.23 | 9,290 | 42.72 | 74,877 USD | -155,691 |
| Nikkei 225 | Daily | n/a | 545 | 64.95 | 19,972 USD | -16,931 |
| Dow Jones | Daily | n/a | 986 | 62.58 | 16,708 EUR | -5,776 |
| DAX 40 | Daily | n/a | 804 | 67.16 | 10,190 EUR | -3,925 |
| Dow Jones | 4 hours | n/a | 736 | 59.65 | 5,449 EUR | -4,529 |
| FTSE 100 | Daily | n/a | 704 | 64.35 | 3,570 EUR | -2,821 |
| Gold | Daily | n/a | 686 | 61.22 | 1,054 EUR | -797 |
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.
// ============================================================ // Double Sevens // ProRealAlgos Strategy Library | prorealalgos.com // Type: Mean reversion // Direction: Long only // Timeframe tested: Daily // ============================================================ // --- Settings --- DEFPARAM CumulateOrders = false // --- Parameters --- positionSize = 1 // contracts per trade entryLookback = 7 // buy at a new low of the last closes over this many bars exitLookback = 7 // sell at a new high of the last closes over this many bars trendPeriod = 200 // long only above this moving average // --- Indicators --- trendMA = Average[trendPeriod](close) lowestClose = Lowest[entryLookback](close) highestClose = Highest[exitLookback](close)
14 more lines: the entry and exit rules.
Read this first
Questions
Yes. It is a simple long only ProOrder system with one entry and one exit rule. The rewrite has not been compile checked, so backtest it before going live.
DAX 40, Dow Jones, EUR/USD, FTSE 100, Gold, Nikkei 225, S&P 500 and Nasdaq 100. All listed runs were profitable, with Nasdaq 100 Daily the best at EUR 14,159.6 over 743 trades.
The best run on Nasdaq 100 Daily had a max drawdown of EUR 2,786 with a 63.12% win rate. Without a stop, a single trade can go deeper than past results show.
The 200 day SMA trend filter and the 7 bar lookbacks are meant for daily swings. The one intraday test (EUR/USD 3 minutes) had a far worse drawdown to profit ratio.
Related
Copy trading on US indices is available to ProRealAlgos members as spots open.