Technical analysis · Trend strength
ADX and DMI for Forex: Trend Strength, Direction and Breakout Filters
ADX describes the persistence of directional movement, while +DI and −DI indicate which side dominates. Combining them can define a trend filter, but a high or rising ADX does not guarantee that a trend will continue.
Strength and direction belong to different lines
The Directional Movement System contains positive directional movement, negative directional movement and the Average Directional Index. ADX summarises how unequal the smoothed positive and negative components have been. It does not carry a positive sign for an uptrend and a negative sign for a downtrend.
A rising ADX can therefore accompany a sustained fall in EUR/USD. Direction must come from +DI versus −DI, price structure or another explicitly defined filter. A falling ADX describes reduced directional dominance; it does not automatically mean the price trend has reversed.
Traders often use zones around 20 or 25 when discussing trend strength. Those thresholds are conventions to test, not boundaries between safe and unsafe trades. A value of 24.9 and one of 25.1 should not be treated as radically different economic conditions.
Wilder’s calculation, step by step
Let Up = current high − previous high and Down = previous low − current low. Set +DM = Up only when Up is positive and greater than Down; otherwise use zero. Set −DM = Down only when Down is positive and greater than Up; otherwise use zero. Ties give zero to both, so one candle does not contribute positive movement to both directions.
True Range is the largest of current high minus low, the absolute high-to-previous-close distance and the absolute low-to-previous-close distance. Smooth +DM, −DM and TR with the same Wilder method. Then +DI = 100 × smoothed(+DM)/smoothed(TR) and similarly for −DI.
Calculate DX = 100 × |+DI − (−DI)|/(+DI + (−DI)). ADX is a further Wilder-smoothed average of DX, commonly using 14 periods. Handle zero denominators and allow enough warm-up history. MetaQuotes’ source code documents the directional-selection and smoothing implementation. Official ADX Wilder source.
Read combinations instead of isolated thresholds
If +DI is above −DI and ADX is rising, positive directional movement currently dominates and that imbalance has recently strengthened. If −DI is above +DI with rising ADX, the corresponding interpretation is negative dominance. When the DI lines repeatedly exchange positions, a trend-following entry rule may encounter frequent reversals.
A high ADX after an extended move can be late rather than attractive. The indicator has multiple smoothing stages, so it naturally reacts with delay. A sharp reversal can also inherit an elevated reading from the preceding trend. Inspect the actual price path and the current DI ordering.
Use ADX as a filter whose contribution can be measured. If a price-breakout rule performs similarly without it, the additional condition may only reduce sample size. Adding another line should have an observable purpose beyond making the chart look more sophisticated.
A closed-bar ADX breakout study
This example uses EUR/USD H4 and Wilder ADX14. It is an explicit research framework with no claimed performance record.
- At completed bar t, require ADX at or above 25 and greater than its value three bars earlier. Require +DI(t) above −DI(t).
- Require close(t) above the highest high of the 20 completed bars immediately before t. Exclude the signal bar from that breakout level.
- Enter long at the next available ask. Skip if spread exceeds 2 pips or the fill is more than 0.2 ATR14 above the signal close. Use SMA-ATR14 for the separate risk calculation and record that choice.
- Place the stop 0.25 ATR below the lowest low of the five completed candles ending at t. Set the target at twice the initial actual entry-to-stop distance.
- Exit earlier on the next quote after +DI closes below −DI, or after 18 completed H4 candles. Apply the earliest stop, target or timed/directional exit. An ADX dip alone is not an exit in this version.
- Allow one position and limit planned loss including estimated costs to 0.5% of equity. Require a fresh 20-bar breakout before another attempt.
For shorts, reverse the DI ordering and use a close below the prior 20-bar low, with the stop above recent highs.
Worked DI arithmetic and EUR/USD risk
Assume the smoothed true-range average is 20 pips, smoothed positive movement is 6 pips and smoothed negative movement is 2 pips. +DI is 30 and −DI is 10. DX is therefore 100 × 20/40 = 50. ADX need not equal 50 because it also reflects earlier DX readings through its smoothing.
Suppose actual ADX is 28 versus 23 three bars earlier, +DI remains dominant and a qualifying price breakout occurs. A hypothetical long fills at 1.1020, while the stop calculation gives 1.0980. The initial 40-pip risk places the 2R target at 1.1100.
A USD 10,000 account at 0.5% planned risk provides USD 50. With USD 10 per pip per standard EUR/USD lot, pre-cost size is 0.125 lots; reduce and round down for commission, execution assumptions and the volume step. If the next fill is too far beyond the signal close, the framework skips it even though ADX remains strong.
Limitations and useful comparisons
ADX can rise after a news spike without producing a durable trend, stay elevated during the first part of a reversal, or remain low while a gentle trend develops. A strict threshold can therefore admit some poor trades and exclude some useful ones. Smoothing reduces noise but cannot eliminate this tradeoff.
Compare the breakout rule with and without ADX, using identical entries, exits, costs and risk limits. Inspect nearby thresholds and periods to see whether an apparent improvement is stable. Use chronological holdout data, realistic bid/ask spreads, commission, financing and slippage.
Report trade count as well as net expectancy and drawdown. Filtering a large set down to a handful of successful historical trades can create a misleading result. Review performance during ranges, mature trends, policy shocks and quiet sessions. Do not infer market direction from a chart that displays only the ADX curve.
The MT4/MT5 implementation distinction
MT5 offers Average Directional Movement Index and a separate Average Directional Movement Index Wilder. The latter is the intended implementation for this article. Selecting the generic ADX and entering 14 does not establish that its values will match. MetaQuotes identifies the separate Wilder version.
On MT4, verify a suitable Wilder implementation before reproducing these rules; do not assume the standard ADX is numerically interchangeable. Check the resulting ADX, +DI and −DI readings against known bars and retain sufficient history for initialisation.
For MT5 automation, iADXWilder provides buffer 0 for ADX, buffer 1 for +DI and buffer 2 for −DI. Evaluate the last completed bar after the next begins. Official buffer reference. Save the implementation name with each test so a later platform change does not silently alter the strategy.
Sources and further reading
Official documentation and research checked for this update. Broker terms depend on the contracting entity and can change.
