# forge.ta.macd

```python
forge.ta.macd(source: ArrayLike, fast_period: int = 12, slow_period: int = 26, signal_period: int = 9) -> dict[str, np.ndarray]
```

MACD: the fast EMA minus the slow EMA, its signal line and the gap between them.

Both EMAs are seeded on the first value (MetaTrader 5). The signal is the simple average of the
MACD line, as MetaTrader 5 computes it. The histogram is the MACD line minus the signal.

Since Forge API 1.

## Class forge.ta.MACD

```python
forge.ta.MACD(**inputs: Any) -> None
```

The gap between a fast and a slow EMA, with a signal line and histogram.

MACD = EMA(source, fast_period) - EMA(source, slow_period), both seeded on the first value

signal = the simple average of MACD over signal_period, as MetaTrader 5 computes it

histogram = MACD - signal

Since Forge API 1.
