DEMA Adaptive DMI [BackQuant]DEMA Adaptive DMI
PLEASE Read the following, knowing what an indicator does at its core before adding it into a system is pivotal. The core concepts can allow you to include it in a logical and sound manner.
Conceptual Foundation and Innovation
The DEMA Adaptive DMI blends the Double Exponential Moving Average (DEMA) with the Directional Movement Index (DMI) to offer a unique approach to trend-following. By applying DEMA to the high and low prices, this indicator refines the traditional DMI calculation, enhancing its responsiveness to price changes. This results in a more adaptive and timely measure of market trends and momentum, providing traders with a more refined tool for capturing directional movements in the market.
Technical Composition and Calculation
At its core, the DEMA Adaptive DMI calculates the DEMA for both the high and low prices over a user-defined period. This dual application of DEMA serves to smooth out price fluctuations while retaining sensitivity to market movements. The DMI is then derived from the changes in these DEMA values, producing a set of plus and minus directional indicators that reflect the prevailing trend. Additionally, an Average Directional Index (ADX) is computed to measure the strength of the trend, with the entire process being dynamically adjusted based on the DEMA calculations.
DEMA Application:
The DEMA is applied to both high and low prices to reduce lag and provide a smoother representation of price action.
Directional Movement Calculation: The DMI is calculated using the smoothed price changes, resulting in plus and minus indicators that accurately reflect market trends.
ADX Calculation:
The ADX is computed to quantify the strength of the trend, offering traders insight into whether the market is trending strongly or is in a phase of consolidation.
Features and User Inputs The DEMA Adaptive DMI offers a range of customizable options to suit different trading styles and market conditions:
DEMA Calculation Period: Users can set the period for the DEMA calculation, allowing for adjustments based on the desired sensitivity.
DMI Length: The length of the DMI calculation can be adjusted, providing flexibility in how trends are measured.
ADX Smoothing Period: The smoothing period for the ADX can be customized to fine-tune the trend strength measurement.
Divergence Detection: Optional divergence detection features allow traders to spot potential reversals based on the DMI and price action.
Visualization options include static high and low levels to mark extreme DMI thresholds, the ability to color bars according to trend direction, and background hues to highlight overbought and oversold conditions.
Practical Applications
The DEMA Adaptive DMI is particularly effective in markets where trend strength and direction are crucial for successful trading. Traders can leverage this indicator to:
Identify Trend Reversals:
Detect potential trend reversals by monitoring the DMI and ADX in conjunction with divergence signals.
Trend Confirmation:
Use the DEMA-based DMI to confirm the strength and direction of a trend, aiding in the timing of entries and exits.
Strategic Positioning:
The indicator's responsiveness allows traders to position themselves effectively in fast-moving markets, reducing the risk of late entries or exits.
Advantages and Strategic Value
By integrating the DEMA with the DMI, this indicator provides a more adaptive and timely measure of market trends. The reduced lag from the DEMA ensures that traders receive signals that are closely aligned with current market conditions, while the dynamic DMI calculation offers a more accurate representation of trend direction and strength. This makes the DEMA Adaptive DMI a valuable tool for traders looking to enhance their trend-following strategies with a focus on precision and adaptability.
Summary and Usage Tips
The DEMA Adaptive DMI is a sophisticated trend-following indicator that combines the benefits of DEMA and DMI into a single, powerful tool. Traders are encouraged to incorporate this indicator into their trading systems for a more nuanced and responsive approach to trend detection and confirmation. Whether used for identifying trend reversals, confirming trend strength, or strategically positioning in the market, the DEMA Adaptive DMI offers a versatile and reliable solution for trend-following strategies.
Thus following all of the key points here are some sample backtests on the 1D Chart
Disclaimer: Backtests are based off past results, and are not indicative of the future.
INDEX:BTCUSD
INDEX:ETHUSD
BINANCE:SOLUSD
Dmiadx
Directional Movement Index FLEXA common problem experienced by short term traders using DMI/ADX is that the session breaks results in carry-over effects from the prior session. For example, a large gap up would result in a positive DMI, even though momentum is clearly negative. Note the extremely different results in the morning session, when the gap is reversed.
The DMI-FLEX algoritm resets the +DI and -DI values to the prior session ending midpoint, so that new momentum can be observed from the indicator. (Note for Pinescript coders: rma function does not accept series int, thus the explicit pine_rma function)
DMI-FLEX has the added feature that the ADX value, instead of a separate line, is shown as shading between the +DI and -DI lines, and the color itself is determined by whether +DI is above -DI for a bullish color, or -DI is above +DI for a bearish color.
DMI Flex also gives you the flexibility of inverse colors, in case your chart has inverted scale.
Summary and How to use:
1) Green when +DI is above -DI
2) Red when -DI is above +DI
3) Deeper shading represents a higher ADX value.