Join waitlist
Strategies / Trend / MACD and EMA 100 Trend Long

MACD and EMA 100 Trend Long

The system buys 1 contract when the close is above its 100-period EMA and the MACD line is above its signal line. It sells when both conditions reverse, and it uses no stop or profit target.

TrendLong onlySwingNasdaq 100Daily
3.04Profit factor
22,474Net profit EUR
40.25%Win rate
159Trades
-5,074Max drawdown
141Avg trade

Best run of 31. Nasdaq 100, Daily, spread 3, from run pf:2026-10-05-NAS100-D.tsv:11.

Entry rules, long

  1. The MACD line uses periods 12, 26 and 9, and the signal line is a 9-period EMA of the MACD line.

Exit rules

  1. The trade closes at market when the close is below the 100-period EMA and the MACD line is below its signal line.

Test conditions

PeriodUp to 2026-10-05
InstrumentNasdaq 100, 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-05

Every run

Markets and timeframes tested

MarketTimeframePFTradesWin %NetMax DD
Nasdaq 100Best runDaily3.04 15940.2522,474 EUR-5,074
Nikkei 225Daily2.16 15436.3658,254 USD-12,909
Nasdaq 1004 hours1.63 46336.2917,767 EUR-4,301
S&P 5004 hours1.42 47033.403,339 EUR-799
USD/JPYDailyn/a 18534.591,247,630 USD-467,250
USD/JPY30 minn/a 2,98227.46719,130 USD-187,590
USD/JPY1 hourn/a 2,09528.35462,850 USD-297,670
USD/JPY10 minn/a 3,14825.41238,110 USD-131,860
USD/JPY15 minn/a 3,12525.92163,520 USD-161,390
Nikkei 2254 hoursn/a 40832.8429,327 USD-9,504
Dow JonesDailyn/a 21539.0726,090 EUR-7,476
Nikkei 2251 hourn/a 1,55729.0921,733 USD-9,645
Nasdaq 10030 minn/a 2,91128.8913,239 EUR-3,396
Nasdaq 1001 hourn/a 1,77429.7612,978 EUR-5,515
DAX 401 hourn/a 1,68229.3112,825 EUR-3,750
Dow Jones4 hoursn/a 15835.4412,739 EUR-4,472
DAX 40Dailyn/a 23535.7411,068 EUR-4,783
DAX 4030 minn/a 3,03626.588,766 EUR-4,765
Dow Jones1 hourn/a 62431.098,369 EUR-6,484
DAX 404 hoursn/a 49932.066,776 EUR-4,312
Nasdaq 10015 minn/a 2,92127.326,724 EUR-3,479
GBP/USDDailyn/a 21032.386,277 USD-5,894
Nasdaq 10010 minn/a 2,96725.785,698 EUR-5,082
Nasdaq 1005 minn/a 3,03526.434,629 EUR-4,216
S&P 500Dailyn/a 22333.183,353 EUR-1,144
GoldDailyn/a 22130.323,048 EUR-1,151
Gold4 hoursn/a 47129.302,386 EUR-1,426
Gold30 minn/a 3,00926.552,172 EUR-731
Gold1 hourn/a 1,79327.442,070 EUR-1,142
S&P 5001 hourn/a 1,84929.581,800 EUR-831
S&P 50030 minn/a 3,00629.011,311 EUR-1,283

Charts

Results by run

Top 10 of 31 runs. The full list is in the table above.

Above 1.0 made money, below 1.0 lost money.

The code

ProBuilder code, as tested

// ==============================================================
// MACD and EMA 100 Trend Long
// ProRealAlgos Strategy Library  |  prorealalgos.com
// Type: Trend
// Direction: Long only
// Timeframe tested: Daily
// ==============================================================

DEFPARAM CumulateOrders = false

myMacd = MACDLine[12,26,9](close)
signal = ExponentialAverage[9](myMacd)
ema = ExponentialAverage[100](close)

9 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

MACDEMA
Longer historyRe-run on up to 1,000,000 barsNasdaq 100 · Daily · older data 307.20 EUR

Nasdaq 100 had no history beyond the standard run, so both runs used 10,000 bars.

Nasdaq 100 · Daily

Bars available10,000
Net, standard 200,000-bar run22,473.80 EUR
Net, long run22,781.00 EUR
Net on the older data alone307.20 EUR
Read this firstKnown weaknesses2 points
  • The code sets no stop loss, so a losing trade stays open until an exit signal arrives.
  • Results include the spread only. Commissions and overnight financing are not included.

Questions

About this strategy

Can I run MACD and EMA 100 Trend Long 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 31 market and timeframe combinations. The best run was Nasdaq 100, Daily, with a profit factor of 3.04 over 159 trades.

How large was the drawdown?

The best run had a maximum drawdown of 5,074 EUR at the tested position size, against a net result of 22,474 EUR.

Does it trade long, short or both?

It only takes long trades.

Related

Strategies like this one

Slow MACD Slope

Uses the same indicator.

6.80 PF · 7,305 trades

Volatility Spike Regression Long

Best run on the same market, Nasdaq 100.

1.22 PF · 1,850 trades

MACD Crossover Volatility Stop Filter

Also a trend strategy.

3.02 PF · 144 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