tsEvaFillSeries {RtsEva} | R Documentation |
This function takes a vector of timestamps and a corresponding series with missing values, and fills the missing values by taking the average of the surrounding values.
tsEvaFillSeries(timeStamps, series)
timeStamps |
A vector of timestamps. |
series |
A vector representing the time series with missing values. |
A vector with missing values filled using a moving average approach.
timeStamps <- c(1, 2, 3, 4, 5, 6, 7, 8, 9, 10)
series <- c(1, 2, NA, 4, 5, NA, 7, 8, NA, 10)
filledSeries <- tsEvaFillSeries(timeStamps, series)
filledSeries