EMupdateGets {lme4} | R Documentation |
A generic replacement function used in the EM and ECME optimization algorithms for linear mixed-effects models.
EMupdate(x, nlev) <- value
x |
an lmeStruct or pdMat object |
nlev |
integer: the number of levels of the grouping factor corresponding to the random-effects structure |
value |
a matrix with the triangular factor from an orthogonal-triangular decomposition of the modal values of the random-effects and their precision matrices |
an object of the same class as x
Douglas Bates bates@stat.wisc.edu and Saikat DebRoy saikat@stat.wisc.edu
library(lme4) data(Oxboys, package = "nlme") m3 <- pdLogChol(~ age) m3 as(m3, 'pdmatrix') <- crossprod(model.matrix(formula(m3), Oxboys)) show(m3) EMupdate(m3, length(levels(Oxboys$Subject))) <- diag(2) show(m3)