The MACD array function computes the Moving Average Convergence/Divergence (MACD) curve and the associated signal line using an Exponential Moving Average (EMA) value of two period lengths – 12 and 26. The periods can be any duration – daily, weekly, monthly are typical. The function uses the VAMI (Value Added Monthly Index) which can be generated using the SP_VAMI function. All these functions use the Excel array functionality.
Developed by Gerald Appel in the late seventies, the MACD indicator is one of the simplest and most effective momentum indicators available. The MACD turns two trend-following indicators, moving averages, into a momentum oscillator by subtracting the longer moving average from the shorter moving average. As a result, the MACD offers the best of both worlds: trend following and momentum. The MACD fluctuates above and below the zero line as the moving averages converge, cross and diverge. Traders can look for signal line crossovers, centerline crossovers and divergences to generate signals. Because the MACD is unbounded, it is not particularly useful for identifying overbought and oversold levels.
MACD can also be constructed as a histogram (use the MACD line - Signal line). MACD histogram is often easier for novices to use. Professional market technical analysts agree that MACD requires experience and judgment to use as Appel intended. Gerald Appel doesn't recommend its use as a purely mechanical indicator. The most common problem traders experience when using the MACD indicator is frequent whipsaws which may cause chronic small losses.