Skip to content
All library documents

MACD Histogram Extremes and Historical Average Ranges

Article Strategy library · Author: ChaoZhang

Summary

This indicator extends a standard MACD by tracking the signal-line values at zero crossings of the MACD histogram. It accumulates negative signal-line readings at upward histogram crossings and positive readings at downward crossings, then plots their respective averages as a range around the MACD display. Histogram colors distinguish whether momentum is rising or falling and whether it is above or below zero. The script also marks conditions it labels bullish or bearish divergences and submits long or short entries when those conditions occur.

The parameters set fast, slow, and signal averages to 12, 26, and 23 periods, and the example backtest settings use Bitcoin futures over a short interval. The document gives no performance statistics or evidence that the average levels improve entries. Because the averages depend on accumulated crossing observations and the code divides by the number of qualifying observations, early or sparse data can make the plotted levels unreliable. The supplied material does not establish how the signals perform across other assets or market regimes.

Key ideas

  • The indicator uses exponential moving averages to calculate MACD, its signal line, and histogram.
  • It averages selected signal-line readings at histogram zero crossings to display historical upper and lower reference levels.
  • Histogram colors encode direction of change and whether momentum is above or below zero.
  • The script submits long and short entries based on conditions it labels bullish and bearish divergences.
  • No performance statistics are provided, and the average levels may be unreliable when qualifying observations are sparse.

Tags

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