MACD


Summary

The main MACD line (blue line)

Remarks

MACD line: difference between the 12 and 26 days EMAs

Syntax

public IndicatorDataSeries MACD{ get; }

Example 1

//...
private MacdCrossOver _macdCrossOver;
[Output("MACD")]
public IndicatorDataSeries Macd { get; set; }
protected override void Initialize()
{
    _macdCrossOver = Indicators.MacdCrossOver(LongCycle, ShortCycle, Period);
}
public override void Calculate(int index)
{
    Macd[index] = _macdCrossOver.MACD[index];
    //...
}