Factors Directory

Quantitative Trading Factors

Directional Momentum Discrete Indicator

Overbought and OversoldTechnical FactorsMomentum Factor

factor.formula

Upward Momentum (DMZ) =

Downward Momentum (DMF) =

Directional Momentum Index (DIZ) =

Negative Momentum Index (DIF) =

Directional Momentum Dispersion Index (DDI) =

If the denominator is 0, let DDI =

in:

  • :

    The highest price on day t

  • :

    The lowest price on day t

  • :

    The highest price on day t-1

  • :

    The lowest price on day t-1

  • :

    The upward momentum value on day t. When the sum of today's highest price and lowest price is not greater than that of the previous day, DMZ is 0; otherwise, DMZ is the greater of the absolute value of the difference between today's highest price and the previous day's highest price and the absolute value of the difference between today's lowest price and the previous day's lowest price.

  • :

    The downward momentum value on day t. When the sum of today's highest price and lowest price is greater than the previous day, DMF is 0; otherwise, DMF is the greater of the absolute value of the difference between today's highest price and the previous day's highest price and the absolute value of the difference between today's lowest price and the previous day's lowest price.

  • :

    The sum of DMZ from day t-N+1 to day t, that is, the sum of upward momentum within N days.

  • :

    The sum of DMF from day t-N+1 to day t, that is, the sum of downward momentum within N days.

  • :

    The time window size represents the length of the lookback period for calculating momentum. The default value is 20 trading days. The choice of N affects the sensitivity of DDI. A smaller N value makes DDI more sensitive, while a larger N value makes it smoother.

  • :

    The positive momentum index on day t represents the percentage of upward momentum in the N-day period to the total momentum.

  • :

    The negative momentum index on day t represents the percentage of downward momentum in the N-day period to the total momentum.

  • :

    The directional momentum dispersion indicator on day t, calculated by subtracting DIF from DIZ, reflects the relative strength of market momentum.

factor.explanation

The Directional Momentum Dispersion Indicator (DDI) compares the size of upward and downward momentum and smoothes it to identify potential trend reversals and overbought and oversold areas. The core logic of DDI is to measure the relative strength of upward and downward price fluctuations over a period of time. When the DDI value is high, it may indicate that the market is overbought or that upward momentum is dominant; conversely, when the DDI value is low, it may indicate that the market is oversold or that downward momentum is dominant. Investors can use the trend changes and extreme value areas of DDI to assist in judging the strength of market trends and potential reversal opportunities. In addition, this indicator can also be used in conjunction with other technical indicators to improve the accuracy of trading decisions. The DDI indicator is suitable for short-term and medium-term trading, and can help investors quickly capture turning points in market momentum.

Related Factors