Measures trend STRENGTH regardless of direction; +DI and −DI report direction. ADX above 25 = trending; below 20 = ranging.
+DM = up-move if larger than down-move else 0 −DM = mirror DI = 100 · smoothed(DM) / smoothed(TR) ADX = smoothed |+DI − −DI| / (+DI + −DI) × 100
Regime filter: only take trend-following trades when ADX > 25; only take range trades (short strangle etc.) when ADX < 20.
ADX itself is direction-agnostic — you always need +DI/−DI to know which way. Slow-reacting on regime changes.
Nifty 50 daily bars with ADX (with DMI) pre-loaded:
1 strategy uses ADX (with DMI):