top of page

Average Directional Index (ADX)

Updated: May 29

What it is and how to use it


What is it?

The Average Directional Index (ADX) is a technical indicator used to measure the strength of a trend, regardless of its direction. It helps you identify whether the market is trending or ranging, which is crucial for applying the appropriate trading strategy.


Who made it?

The Directional Movement System, including the DI and ADX, was introduced by J. Welles Wilder in his 1978 book "New Concepts in Technical Trading Systems."


How is it calculated?

The ADX calculation involves several steps, including determining the True Range (TR) and Directional Movement (DM), and then calculating the Directional Indicators (DI+ and DI-), followed by the ADX itself.


Calculating DI+ and DI-:

  1. Calculate the differences:

    1. upMove = high - high[1]

    2. downMove = low[1] - low

  2. Determine the Directional Movement (DM):

    1. DMplus = 0

    2. DMminus = 0

    3. if (upMove > downMove and upMove > 0) then DMplus = upMove endif

    4. if (downMove > upMove and downMove > 0) then DMminus = downMove endif

  3. Calculate the True Range (TR):

    1. TR1 = high - low

    2. TR2 = abs(high - close[1])

    3. TR3 = abs(low - close[1])

    4. TRValue = max(TR1, max(TR2, TR3))

  4. Smooth the DM and TR over a specific period (e.g., 14 periods):

    1. smoothedDMplus = summationperiod / summationperiod

    2. smoothedDMminus = summationperiod / summationperiod

  5. Calculate the Directional Indicators (DI+ and DI-):

    1. DIplusValue = 100 * (smoothedDMplus / summationperiod)

    2. DIminusValue = 100 * (smoothedDMminus / summationperiod)

  6. Calculate the Directional Index (DX):

    1. DX = 100 * abs(DIplusValue - DIminusValue) / (DIplusValue + DIminusValue)

  7. Smooth the DX values over the specified period to get the ADX:

    1. ADXValue = averageperiod


Code (ProRealTime)


How do you use the ADX?

Trend Strength: 

The ADX line measures the trend strength, regardless of direction. An ADX value above 25 typically indicates a strong trend, while an ADX value below 20 usually indicates a weak or non-trending market.


Filter for Other Indicators:  ADX can filter signals from other indicators, ensuring trades are only taken in strong trending conditions.


FAQ

Q: Is ADX a leading or lagging indicator?

A: ADX is a lagging indicator. It measures the strength of a trend without considering its direction, helping you identify strong trends.


Q: What are the best settings for ADX?

A: The default setting for ADX is 14 periods. You can adjust it to fit your trading style and the asset you're analyzing.


Q: How does ADX compare to RSI?

A: ADX measures trend strength, while RSI measures the speed and change of price movements. ADX is great for confirming strong trends, while RSI helps spot overbought and oversold conditions.


Strategies using ADX

  • None so far.

bottom of page