This function allows the user to make out-of-sample predictions from an LME model.
mixoutsamp(model, newdata)Object of class lme containing the fitted LME model
Data frame containing data for which to make predictions. The response variable should be set to NA for the rows of the data the user wishes to make predictions for. The columns in the data should have the same names as those used to fit the model. The variables should also be of the same type as in the data used to fit the mixed model (numeric, factor etc).
List containing preddata and random. Data frame preddata is a version of newdata updated to contain columns corresponding to the fixed effects values (fixed),
random effects values (random), and fitted values (fitted).
Data frame random contains the values of random effects components for each individual.