gamm
. It extracts
the estimated covariance matrix of the data from an lme
object, allowing the
user control about which levels of random effects to include in this
calculation.extract.lme.cov(b,data,start.level=1)
lme
lme
.The calculation is not optimally efficient, since it forms the full matrix, which may in fact be sparse. In applications in which the main objective is to allow non-independent `errors' in GAMs this is unlikely to cause great computational losses.
lme
see:Pinheiro J.C. and Bates, D.M. (2000) Mixed effects Models in S and S-PLUS. Springer
For details of how GAMMs are set up here for estimation using lme
see:
Wood, S.N. (manuscript) Tensor product smooth interaction terms in
Generalized Additive Mixed Models.
gamm
library(nlme)
data(Rail)
b <- lme(travel~1,Rail,~1|Rail)
extract.lme.cov(b,Rail)
Run the code above in your browser using DataLab