Smoothed moving average (Wilder)

rmamoving_averagesForge API 1

Wilder's smoothing: a slow average seeded with the mean of the first N values.

Inputs

NameTypeDefaultRange
sourcesourceclose
periodint131 to 5000

Outputs

NameTypeRequiredDescription
rmavalueOptionalcolor theme.accent, style line, width 1
Warm-up
period - 1 bars (12 at the defaults)
Repaints
No
Parity
MetaTrader 5, within 1e-12

Formula

RMA[period-1] = mean of the first period values

RMA[i] = (RMA[i-1] * (period - 1) + x[i]) / period

After a gap the average starts again with a new seed.