Join today
Strategies / Momentum / ATR Momentum

ATR Momentum: Trading One-ATR Bars in ProRealTime

The system jumps in the direction of any bar that closes more than one ATR(10) away from the previous close, long or short. It exits when price closes back through a 5-period SMA or hits a 1% stop, and it trades intraday on index and gold charts.

MomentumLong & shortIntradayS&P 50030 min
n/aProfit factor
-9,682Net profit EUR
34.31%Win rate
15,021Trades
-13,588Max drawdown
-0.64Avg trade

Best run of 16. S&P 500, 30 min, spread 1, from run sweeps:2026-09-07-USA500-30m-opt.tsv:13.

Entry rules, long

  1. Members only
  2. No position is open

Entry rules, short

  1. Members only
  2. No position is open

Exit rules

  1. Stop loss 1% from entry
  2. Members only
  3. Close a short when price closes above the 5-period SMA

Test conditions

PeriodUp to 2026-09-07
InstrumentS&P 500, 30 minutes
Spread1 points
Contracts1
Starting capital1,000,000
CostsSpread only. Commissions and overnight financing are not included.
BarsUp to 200,000 bars, fewer where the instrument has less history
Last tested2026-09-07

Parameters

positionSize
Contracts per trade
1
atrPeriod
ATR length
10
exitPeriod
Exit average length
5
stopLossPct
Protective stop, percent
1

Every run

Markets and timeframes tested

MarketTimeframePFTradesWin %NetMax DD
S&P 500Best run30 minn/a 15,02134.31-9,682 EUR-13,588
Gold30 minn/a 13,46734.71-2,734 EUR-6,539
Gold1 hourn/a 8,25833.31-3,242 EUR-5,154
Gold5 minn/a 13,13829.25-7,097 EUR-7,103
Gold15 minn/a 12,88728.79-7,832 EUR-7,838
S&P 5001 hourn/a 9,18031.60-9,240 EUR-9,466
DAX 401 hourn/a 8,26435.83-12,224 EUR-15,031
S&P 50015 minn/a 14,17630.44-14,045 EUR-14,045
S&P 5005 minn/a 14,39226.26-15,699 EUR-15,736
Nasdaq 10030 minn/a 14,62434.30-27,138 EUR-34,452
Nasdaq 1001 hourn/a 9,37230.28-28,713 EUR-28,714
DAX 4030 minn/a 13,95134.59-31,864 EUR-42,172
Nasdaq 10015 minn/a 13,57033.64-32,162 EUR-32,216
Nasdaq 1005 minn/a 13,61231.45-36,494 EUR-36,558
DAX 405 minn/a 14,47929.42-45,431 EUR-45,664
DAX 4015 minn/a 13,92131.39-47,830 EUR-47,830

Charts

Results by run

Net profit against max drawdown

Net profitMax drawdown
0-50K-25KGold · 30 minGold · 1 hourGold · 5 minGold · 15 minS&P 500 · 1 hourS&P 500 · 30 minDAX 40 · 1 hourS&P 500 · 15 minS&P 500 · 5 minNasdaq 100 · 30 minNasdaq 100 · 1 hourDAX 40 · 30 minNasdaq 100 · 15 minNasdaq 100 · 5 minDAX 40 · 5 minDAX 40 · 15 min

The code

ProBuilder, rewritten to house standard

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.

// ============================================================
// ATR Momentum
// ProRealAlgos Strategy Library  |  prorealalgos.com
// Type: Momentum
// Direction: Long & short
// Timeframe tested: 30 minutes
// ============================================================

// --- Settings ---
DEFPARAM CumulateOrders = false

// --- Parameters ---
positionSize = 1     // contracts per trade
atrPeriod = 10       // ATR length
exitPeriod = 5       // exit average length
stopLossPct = 1      // protective stop, percent of entry price

// --- Indicators ---
atrValue = AverageTrueRange[atrPeriod](close)
exitMA = Average[exitPeriod](close)

26 more lines: the entry and exit rules.

Read this first

Known weaknesses

  • Every one of the 15 market and timeframe runs lost money, from EUR -2,734.20 on Gold 30 minutes to EUR -47,829.60 on DAX 40 15 minutes.
  • The best run (S&P 500, 30 minutes) still ended at EUR -9,682.25 over 15,021 trades, with an average trade of EUR -0.64.
  • Win rates sat around 26% to 36%, and the short SMA exit cuts winners early, so the few wins do not cover the many small losses.
  • Profit factor was not recorded because only parameter sweep data exists, and the stats come from the code version before the rewrite.

Indicators used

ATRSMA

How to load it

  1. Copy the code with the copy button above the code block.
  2. In ProRealTime, open a chart of the instrument and timeframe you want to test, then open ProOrder > New trading system and choose "Create with programming".
  3. Paste the code, give the system a name and save it.
  4. Click "Backtest", set your own spread and position size, and run it before you consider trading it live.

Questions

About this strategy

Can I run ATR Momentum live in ProOrder?

The code runs as a ProOrder system with 1 contract and a 1% stop. Given that no tested run was profitable, it makes more sense as a study piece than a live system.

Which markets were tested?

Gold, S&P 500, DAX 40 and Nasdaq 100 on 5, 15, 30 minute and 1 hour charts. All 15 runs ended negative, and Gold lost the least.

How deep did the drawdown get at 1 contract?

On the S&P 500 30 minute chart the maximum drawdown was EUR 13,587.60 trading 1 contract. On DAX 40 15 minutes it reached EUR 47,829.60.

Why test it on intraday charts?

A one-ATR bar on a short chart is a frequent event, which gives thousands of trades to judge the idea. Here the higher trade count mainly made the losses clearer.

Related

Strategies like this one

Bollinger Squeeze

Uses the same indicator.

14.30 PF · 86 trades

Candle Body Sum Intraday

Best run on the same market, S&P 500.

2.86 PF · 124 trades

Twelve Minus Two Momentum

Also a momentum strategy.

12.00 PF · 52 trades

Want to see which momentum ideas held up better? Join the ProRealAlgos community waitlist.

Copy trading on US indices is available to ProRealAlgos members as spots open.

Past backtest results do not guarantee future results. This is not financial advice. Curated and maintained by ProRealAlgos. ProRealTime™ is a trademark of ProRealTime SAS. prorealalgos.comStatsDocs