powered by
Function to calculate the moving average of a given numeric vector. The order of the moving average may be customized by the user (man argument).
man
ma(data, man = 10, warnings = FALSE)
A numeric vector (e.g. a numeric column of a dataframe).
numeric
dataframe
An integer value specifying the order of the moving average applied to the data. By default, man = 10.
integer
man = 10
A logical value specifying the show of warning messages. By default, warnings = FALSE.
logical
warnings = FALSE
This function returns a vector with the moving average of the input data.
# NOT RUN { data("munich_pollen") ma(data = munich_pollen$Betula, man = 10, warnings = FALSE) # }
Run the code above in your browser using DataLab