All indicators

TOFF MACD DEMA Strategy

May 22, 2020

Static chart image
SignalsOscillatorsMoving Averages

The TOFF MACD DEMA Strategy tool provides a quantitative framework for testing trading signals based on the zero-line crossovers of a DEMA-based MACD indicator. Unlike traditional MACD strategies that focus on crossovers between the MACD and Signal lines, this strategy specifically targets momentum shifts by identifying when the MACD line crosses above or below a user-defined threshold, typically the zero level.

Usage

The strategy is primarily used to identify trend reversals and momentum breakouts. A long position is initiated when the MACD DEMA line crosses over the designated "Long Value" (defaulting to 0), signaling bullish momentum. Conversely, a short position is entered when the line crosses under the "Short Value" (defaulting to 0), suggesting bearish pressure.

Users can apply this strategy to various timeframes to analyze the efficacy of zero-lag MACD crossovers compared to standard EMA-based MACD indicators. The inclusion of backtesting date ranges allows for specific historical performance evaluation during different market regimes.

Details

This strategy utilizes the Double Exponential Moving Average (DEMA) to calculate the MACD line, which reduces the lag inherent in standard Moving Average Convergence Divergence indicators. The DEMA is calculated by taking a single EMA and subtracting it from twice the value of an EMA applied to that same EMA.

The core components include:

  • DEMA Fast: A shorter-period DEMA of the closing price.
  • DEMA Slow: A longer-period DEMA of the closing price.
  • MACD Zero Lag Line: The difference between the DEMA Fast and DEMA Slow.
  • Signal Logic: Positions are triggered based on the intersection of the MACD Zero Lag Line and the zero threshold, rather than the secondary signal line crossover.

Settings

Backtest Period

  • Backtest Start Year/Month/Day: Defines the starting date for the strategy simulation.
  • Backtest Stop Year/Month/Day: Defines the ending date for the strategy simulation.

Indicator Configuration

  • DEMA Courte: The period for the fast DEMA calculation (default 12).
  • DEMA Longue: The period for the slow DEMA calculation (default 26).
  • Signal: The period for the signal line calculation (default 9).
  • Lignes: Toggles the visibility of the indicator lines on the chart.

Strategy Thresholds

  • Long Value: The numerical threshold the MACD line must cross above to trigger a long entry.
  • Short Value: The numerical threshold the MACD line must cross below to trigger a short entry.

FAQ

How do I access the TOFF MACD DEMA Strategy?

You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.

What is the advantage of using DEMA over EMA in this strategy?

DEMA reduces the time delay (lag) found in traditional EMA calculations, allowing the MACD to respond more quickly to price changes and potentially providing earlier entry signals.

Can I change the crossover point to something other than zero?

Yes, by adjusting the "Long Value" and "Short Value" settings, you can define custom thresholds for entries to accommodate specific market conditions or volatility levels.

Free indicator

Get free access to this indicator on the platforms below.

TradingView
NinjaTrader
MetaTrader 4/5

Unlock the entire LuxAlgo Library

Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.