[R] help with lme()
bates at stat.wisc.edu
Tue Nov 4 23:13:52 CET 2003
"Bill Shipley" <bill.shipley at usherbrooke.ca> writes:
> Hello. I am trying to determine whether I should be using ML or REML
> methods to estimate a linear mixed model. In the book by Pinheiro &
> Bates (Mixed-effects models in S and S-PLUS, page 76) they state that
> one difference between REML and ML is that "LME models with different
> fixed-effects structures fit using REML cannot be compared on the basis
> of their restricted likelihoods. In particular, likelihood ratio tests
> are not valid under these circumstances."
> I am not sure what "fixed-effects structures" means. Does it mean
> that, as long as the types of contrasts are the same between two
> models, they ARE comparable, but are NOT comparable if the types of
> contrasts are changes?
It means that you would need exactly the same model matrix for the
fixed effects in the two fitted models being compared. That is, you
need the same terms and the same contrasts.
In the REML criterion there is a term involving the determinant of a
matrix derived from the fixed-effects model matrix. If you change
anything about the model matrix (except possibly for the order of the
columns) you will change this determinant and induce a systematic
change in the "log-likelihood" (actually the
log-restricted-likelihood) that is not based on the quality of the
fit. With REML you could fit exactly the same model under two
different parameterizations of the fixed effects and get different
"log-likelihoods". It would be meaningless to conduct a likelihood
ratio test in such circumstances.
It is possible to obtain fits based on REML but then compare
log-likelihoods, not log-restricted-likelihoods. Greg Reinsel has
done some work on this, with favorable results. It is a bit curious
because you don't use the criterion that you actually optimize but it
is effective. My memory is a bit foggy on the details and I don't
have time to grep through the code right now but I think that this may
be what is done in the anova method for lme models.
> Or rather, does it simply mean that one should use t or F tests for
> the fixed effects, and restrict the likelihood ratio tests to the
> random effects only if using REML?
I think I would agree although it is not clear to me how to parse the
last part of that sentence. If it could be rewritten as
"... does it simply mean that, if using REML, one should ... to the
random effects only."
then I agree.
More information about the R-help