I have two set of samples that are time independent. I would like to merge them and calculate the missing values for the times where I do not have values of both. Simplified
Using the zoo package:
zoo
library(zoo) Cz <- zoo(C) index(Cz) <- Cz[,1] Cz_approx <- na.approx(Cz)