[R-sig-ME] lmer fails when too many observations
Asaf Weinstein
asafw.at.wharton at gmail.com
Tue Mar 10 02:52:34 CET 2015
Dear lmer community,
I am trying to run a simulation for a two-way random-effects model with
unbalanced design (ie, unequal number of observations per cell) and no
interaction.
It's especially important for me to be able to run the lmer/blmer functions
when the number of (column and row) random effects is large, say 100, and
with possible replicates in each cell.
The problem is that lmer() works with the full vector of observations, as
opposed to working with the cell averages (which is a sufficient
statistic), and the methods fails pretty quickly when there are replicates
(because the response vector is too big, I suppose). I get the following
error:
*Error in get("checkConv", lme4Env)(attr(opt, "derivs"), opt$par, ctrl =
control$checkConv, : *
* (converted from warning) Model failed to converge with max|grad| =
0.00244385 (tol = 0.002)*
Just to give an example: suppose there are R=100 row effects, C=100 column
effects, and 5 replicates in each cell. The vector of individual
observations is of length 100^5 (lmer fails), while the vector of cell
averages is of length 100^2 (a size which causes no problem for lmer).
My question is whether there is a way to tell lmer() to work with the
sufficient statistic (of course, the conditional covariance is no longer
c*Identity, a fact which is used in the implementation of lmer (according
to documentation) ).
Thank you very much and I hope I was clear!
Asaf
[[alternative HTML version deleted]]
More information about the R-sig-mixed-models
mailing list