To create a regular time series, I expand the iButton temp time series to 1-minute series than summarize to a 30 minute period. This means that a lot of NA's must be interpolated. For example, the iButton measured at 8:22 and 8:52 but the regular series is 8:00, 8:30 and 9:00. For now, I am using linear interpolation, but this ignores knowledge that temperature is lowest right before dawn, hottest in mid afternoon. I tried using a spline fit (na.spline) but that can cause huge outliers when the spine goes crazy.
To create a regular time series, I expand the iButton temp time series to 1-minute series than summarize to a 30 minute period. This means that a lot of NA's must be interpolated. For example, the iButton measured at 8:22 and 8:52 but the regular series is 8:00, 8:30 and 9:00. For now, I am using linear interpolation, but this ignores knowledge that temperature is lowest right before dawn, hottest in mid afternoon. I tried using a spline fit (na.spline) but that can cause huge outliers when the spine goes crazy.
I think correct approach is to use tsSmooth(). See http://stackoverflow.com/questions/4964255/interpolate-missing-values-in-a-time-series-with-a-seasonal-cycle
I will try this soon.