[R-sig-ME] [R] sparse matrices in lme4

Douglas Bates bates at stat.wisc.edu
Tue May 25 01:48:10 CEST 2010


On Mon, May 24, 2010 at 6:24 PM, Robin Jeffries <rjeffries at ucla.edu> wrote:
> I read somewhere (help list, documentation) that the random effects in lme4
> uses sparse matrix "technology".

Yes.  That is why there is such a close link between the Matrix and
lme4 packages.  The sparse matrix methods in the Matrix package are
crucial to the lme4 package.

> I'd like to confirm with others that I can't use a sparse matrix as a fixed
> effect? I'm getting an "Invalid type (S4) " error.

The development version of the lme4 package, called lme4a and only
available from R-forge, has an optional argument sparseX that allows
for this.

In fact, that option is one of the reasons that the development
version has been in development for so long (the programming becomes
much more intricate when you must allow for such an option).

Some day, and I hope not too far in the future, the lme4a package will
be released as lme4.

By the way, questions such as this are probably more suitable for the
R-SIG-Mixed-Models at R-project.org mailing list, which I am cc:ing on
this reply.




More information about the R-sig-mixed-models mailing list