All indicators

Trend Trader Strategy with MACD

Mar 22, 2020

Static chart image
SignalsOscillatorsMoving AveragesVolatility

The Trend Trader Strategy with MACD indicator is a trend-following tool designed to capture market direction using volatility-adjusted price limits and secondary momentum confirmation. It aims to filter out noise in lower timeframes by combining the classic Trend Trader logic with a MACD histogram filter for higher probability entry signals.

Usage

The tool identifies bullish or bearish regimes based on price action relative to a dynamically calculated limit line. A long signal is generated when price crosses above the resistance limit and the MACD histogram is positive (if the filter is enabled). A short signal occurs when price crosses below the support limit.

This strategy is particularly effective in trending markets. Users can employ this for alternating trading strategies, such as switching between leveraged "Bull" and "Bear" tokens. For example, when a buy signal appears on an "ETHBULL" pair, it typically coincides with a sell signal on the "ETHBEAR" pair, allowing traders to capitalize on directional movements in either direction.

Details

The core logic is based on the "Trading the Trend" article by Andrew Abraham from the September 1998 issue of Technical Analysis of Stocks & Commodities (TASC). It utilizes a Weighted Moving Average (WMA) of the Average True Range (ATR) to establish volatility bands around the highest highs and lowest lows over a specified period.

To improve signal quality on shorter timeframes, a MACD confirmation layer is integrated. This ensures that long entries are only initiated when upward momentum is confirmed by a positive MACD histogram, reducing the frequency of whipsaws in sideways markets.

Settings

Main Settings

  • Length: Determines the lookback period for calculating highest highs, lowest lows, and the volatility-adjusted ATR.
  • Multiplier: Sets the distance of the trend limits from price peaks/valleys based on the calculated ATR.
  • Control 'MACD Histogram is positive?' when Buy condition: When enabled, the strategy requires a positive MACD histogram to trigger a long entry.

Date Range

  • From/To Month/Day/Year: Defines the specific backtesting window during which the strategy will execute trades on the chart.

FAQ

How do I use the Trend Trader Strategy with MACD?

Apply the script to your chart and adjust the Length and Multiplier settings to fit your specific asset and timeframe. Use the MACD filter to reduce false signals during periods of low momentum.

Can I turn off the MACD confirmation?

Yes, you can disable the "Control 'MACD Histogram is positive?'" setting in the inputs window to see the raw Trend Trader signals without momentum filtering.

How can I access this tool?

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

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.