repr_sma {TSrepr} | R Documentation |
The repr_sma
computes Simple Moving Average (SMA) from a time series.
repr_sma(x, order)
x |
the numeric vector (time series) |
order |
the order of simple moving average |
the numeric vector of smoothed values of the length = length(x) - order + 1
Peter Laurinec, <tsreprpackage@gmail.com>
repr_sma(rnorm(50), 4)