View source: R/InterpolateMissingValues.R
| InterpolateMissingValues | R Documentation | 
Interpolates missing values, by setting them NaN and then applying spline interpolation
InterpolateMissingValues(Time, Datavector, option = "stine",
PlotIt = TRUE)
Time | 
 [1:n] vector of time,   | 
Datavector | 
 [1:n] numerical vector of data  | 
option | 
 See   | 
PlotIt | 
 TRUE: Evaluates output of function versus input by plots. Default is TRUE  | 
Wrapper for InterpolateOutliers. Missing values are all values which are not is.finite(Datavector)==TRUE.
[1:n] interpolated vector of data
Michael Thrun
InterpolateOutliers
data("airquality")
which(!is.finite(airquality$Ozone))
date_strings = paste("1973", airquality$Month, airquality$Day, sep = "-")
dates = as.Date(date_strings)
vals = InterpolateMissingValues(dates, airquality$Ozone)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.