On Mar 19, 2011; 01:39am Andrzej Galecki wrote: >> I agree with you that caution needs to be exercised. Simply because >> mathematically the same >> likelihood may be defined using different constant.
Yes. But this is ensured by the implementation. If the call to anova() is made with the lm$obj first in the sequence then an error is thrown. If the call is correctly made, with the lme$obj placed first in the sequence, then the log of the likelihood of each object is calculate by nlme:::logLik.lme using the same formula [via lapply(object, logLik, REML), where logLik points to nlme:::logLik.lme]. You will note, as Andrzej Galecki has pointed out, that the logLik.lm of the lm$obj is different from logLik.lme. ## > logLik(fm) 'log Lik.' -950.1465 (df=3) > logLik(fm, REML=T) 'log Lik.' -946.8318 (df=3) Regards, Mark. -- View this message in context: http://r.789695.n4.nabble.com/lmm-WITHOUT-random-factor-lme4-tp3384054p3389249.html Sent from the R help mailing list archive at Nabble.com. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.