[R-sig-ME] Removing p.d. constraint for random effects in lme

Douglas Bates bates at stat.wisc.edu
Mon Apr 6 21:41:45 CEST 2015


It is possible that a fit using lmer in the lme4 package will end up with a
positive semi-definite covariance matrix for the random effects.  The way
that the nlme package fits the model the fitted covariance matrix cannot
have eigenvalues of zero.  They can be very small but not zero.

A considerable amount of the development of the numerical methods in lmer
was to be able to all the fitted covariance matrices to be semi-definite.

As for allowing an indefinite covariance matrix in the model, a covariance
matrix is, by definition, positive semi-definite and i stand by my
statement in

library(fortunes)
fortune("impediment")

On Mon, Apr 6, 2015 at 1:40 PM Ben Bolker <bbolker at gmail.com> wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 15-04-05 05:40 PM, R User wrote:
> > Hi,
> >
> > I am trying to fit a mixed model using lme, with a multivariate
> > response. I would like to try and replicate a SAS proc mixed model
> > that has a type=un structure for random effects.  I am not very
> > experienced using lme, but it seems like one of the differences is
> > that lme constrains the random effect matrix to be positive
> > definite, whereas SAS does not impose this constraint (only
> > variances in SAS are constrained to be nonnegative).  Is there a
> > way to remove this positive definite constraint for random effects
> > from lme and how would this be specified in the model?  My current
> > model looks something like this:
> >
> > lme(value ~ trait -1, data, random = ~ trait -1| line, correlation
> > =  corSymm( form = ~ 1|line/rep), weights = varIdent(form = ~ 1
> > |trait), control=control, method="REML")
> >
> > Thanks, Jacqueline
> >
>
>   This is likely to be difficult.
>
> * Are you looking for positive *semi*definite variance-covariance
> matrices (i.e. eigenvalues/variance >=0), or do you need to allow
> (silly) negative definite var-cov matrices (eigenvalues/variances
> strictly <0)?
>
> * Can you give us more context?  Can you explain what a
> non-positive-definite matrix would mean biologically in your example?
> Can you show us a SAS example where you actually succeeded in fitting
> a non-positive-definite (or negative-definite) variance-covariance matrix?
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.11 (GNU/Linux)
>
> iQEcBAEBAgAGBQJVItLfAAoJEOCV5YRblxUHS7oH/1jQDf+0ms4MfVbUkY9dvHdZ
> YoOYc4l1xEkkoasscYv6EI1gyA9tdK1Bk1z1btpAzjyqlHJ9Di+oKCIi1Ni8L0Mn
> RZSVvF1rXh32/UldaR+Ixe6i0xtaTEmUzR9NABq5HB23xh3zrkfH43ko/R4G3QKS
> VE+Fogs+rbIS1zz6CijOfeytRDB3Qs7AabA6abi1/3xAQuzPQtKntNMBuQJ6RlIj
> V2sCCSgMgy/2BvggNZqspCeK3g4HfXtatKpDKUO0VUac1zydlIQhS888DrkoA2Ng
> 0KO8ABGxSkLx/qQ4YXk0n37QiajFP3MYHg/iV7b2nvmTP4EdupPVe0Af31I/OSw=
> =D2J7
> -----END PGP SIGNATURE-----
>
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>

	[[alternative HTML version deleted]]



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