ema

ema(source, period)
Parameters
  • source (series) – Input series.

  • period (numeric) – MA period.

Returns

series

Returns the exponential moving average of source for the period bars.

\[\begin{split}\alpha &= \frac{2}{\mathrm{period} + 1}\\ \mathrm{ema} &= \alpha \mathrm{source} + (1 - \alpha) \mathrm{ema}_1\end{split}\]