Skip to content
All library documents

MACD and Momentum Difference Crossover Strategy

Article TradingView scripts

Summary

This strategy combines a momentum reading, calculated as the change in a selected price source over a lookback, with a fast-minus-slow moving-average difference. It subtracts that MACD-like difference from momentum to form a delta series. A cross above zero opens a long position, while a cross below zero closes positions. The script also plots momentum, MACD, its signal line, and the histogram, and provides inputs for moving-average types, lengths, data sources, and a backtest date window.

The document offers code and the author’s description of experimenting with merged MACD and momentum indicators, but no performance statistics or testing conclusions. The strategy is long-only and has no explicit stop, target, or position-sizing method in the shown logic. Its combined signal compares series that may have different scales, a concern raised in the accompanying description, so the crossover’s interpretation depends on source selection and parameter choices.

Key ideas

  • Momentum is defined as the difference between a selected source and its value several bars earlier.
  • The signal delta subtracts a fast-versus-slow moving-average difference from momentum.
  • A positive zero crossing opens a long trade, and a negative crossing closes it.
  • The script plots MACD, its signal and histogram, and momentum for inspection.
  • No performance evidence or explicit stop and target rules are provided.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.