Join waitlist
Strategies / Trend / EMA Range Histogram Trend

EMA Range Histogram Trend

The strategy buys when an EMA based state and a range histogram state both turn bullish, and sells short when both turn bearish. An open position closes when the two states no longer agree.

TrendLong & shortSwingDow JonesDaily
n/aProfit factor
15,604Net profit EUR
43.77%Win rate
3,790Trades
-12,443Max drawdown
4.12Avg trade

Best run of 1. Dow Jones, Daily, spread 3, from run sweeps:2026-10-12-DOW30-D-opt.tsv:81.

Entry rules, long

  1. The EMA state is +1 when the adjusted swing level falls below the previous close.
  2. The range state is +1 when the 16-bar average range from 20 bars earlier is above the current bar range.

Entry rules, short

  1. The EMA state is -1 when the adjusted swing level rises above the previous close.
  2. The range state is -1 when the 16-bar average range from 20 bars earlier is below the current bar range.

Exit rules

  1. An open position closes at market when the two states no longer agree.

Test conditions

PeriodUp to 2026-10-12
InstrumentDow Jones, Daily
Spread3 points
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-10-12

Every run

Markets and timeframes tested

MarketTimeframePFTradesWin %NetMax DD
Dow JonesBest runDailyn/a 3,79043.7715,604 EUR-12,443

Charts

Results by run

Net profitMax drawdown

The code

ProBuilder code, as tested

// ==============================================================
// EMA Range Histogram Trend
// ProRealAlgos Strategy Library  |  prorealalgos.com
// Type: Trend
// Direction: Long & short
// Timeframe tested: Daily
// ==============================================================

DEFPARAM CumulateOrders = false

ONCE posrev = 0
ONCE postwo = 0

xa = ExponentialAverage[14](close)
nhh = MAX(high, high[1])
nll = MIN(low, low[1])

39 more lines: the entry and exit rules.

Setup

How to load it

  1. Copy the code with the copy button on 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.

Indicators used

EMASMA
Read this firstKnown weaknesses4 points
  • No profit factor is available, because only sweep results exist for this strategy.
  • The maximum drawdown of 12,443 EUR is large next to the net profit of 15,604 EUR.
  • It was only tested on Dow Jones, so there is no evidence from other markets.
  • The code sets no stop loss, so a losing trade stays open until an exit signal arrives.

Questions

About this strategy

Can I run EMA Range Histogram Trend in ProOrder?

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.

Which markets was it tested on?

It was tested on one combination, Dow Jones, Daily, with 3,790 trades.

How large was the drawdown?

The best run had a maximum drawdown of 12,443 EUR at the tested position size, against a net result of 15,604 EUR.

Does it trade long, short or both?

It trades both long and short.

Related

Strategies like this one

Trend Surfer

Uses the same indicator.

1.04 PF · 10,813 trades

Turtle Trade

Best run on the same market, Dow Jones.

2.42 PF · 6,324 trades

ADX Filtered EMA Cross

Also a trend strategy.

1.15 PF · 607 trades

Put your name on the ProRealAlgos waitlist to trade a tested portfolio instead of single strategies.

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