[R-sig-ME] [R] lme nesting/interaction advice

John Maindonald john.maindonald at anu.edu.au
Thu May 15 02:02:27 CEST 2008


Nevertheless, the carping nature of some of this criticism has been
unwarranted and unfair.  Mixed models in R are hard to suss out!
Sure.  They are hard for most of us to get a grip on, whatever software
one uses.  That is just the way it is.  No doubt the path of the learner
can be smoothed.  The discussion on this list is a help in identifying
what sorts of issues people find difficult.  But it is not all up to  
Douglas.
His part has been to do the really hard part, the code development.
He's also been providing not inconsiderable documentation along the
way, and interesting ongoing commentary onto his progress with the
conceptualization and with the coding, which is a bonus.  It is a work
in progress, and It is all highly educational.

It is fair to put onto others some large part of the task of providing
detailed tutorials and documentation.  They are rising to the challenge;
witness the Baayen book.

I think some contributors may forget how long it took them to get
somewhat on top of mixed models using
whatever-package-it-was-that-cannot-be-named.  Understandably,
they'd prefer not to re-live some elements of that earlier struggle.
The Puritan in my soul responds "It is good for one's intellectual
development!"

Myself, I came via Genstat.  (If there really are
packages-that-cannot-be-named, please tell me!) It was hard going
for quite a while. Genstat, like lme4 to an extent, changed while I  
learned.
Problems that called for something like GLMMs were a huge challenge.
The fudges were used did though provide their own insight, and have
made me highly sensitive to the need to check out data intended for
GLMMs, to the extent possible, before throwing the whole complicated
variance-covariance structure into a total model fit.  Too many who
contemplate these models are loth to do that.  They may then complain
that the fit failed, in a case where one hope that it would fail!

John Maindonald.

John Maindonald             email: john.maindonald at anu.edu.au
phone : +61 2 (6125)3473    fax  : +61 2(6125)5549
Centre for Mathematics & Its Applications, Room 1194,
John Dedman Mathematical Sciences Building (Building 27)
Australian National University, Canberra ACT 0200.


On 15 May 2008, at 4:18 AM, Douglas Bates wrote:

> On Wed, May 14, 2008 at 12:31 PM, Kingsford Jones
> <kingsfordjones at gmail.com> wrote:
>> On Wed, May 14, 2008 at 1:19 AM, Nathaniel Smith <njs at pobox.com>  
>> wrote:
>>> On Wed, May 14, 2008 at 09:28:18AM +0200, Reinhold Kliegl wrote:
>>>>> The pdfs that come with the package are, alas, basically useless
>>>>> (unless you want to fix bugs in lme4).  The best user docs I'm  
>>>>> aware
>>>>> of are the short article in the May 2005 R newsletter, and the
>>>>> papers/book draft written by Harold Baayen et al and available  
>>>>> from
>>>>> his webpage.
>>>>
>>>> I do not think it is very nice to characterize work as ", alas,
>>>> basically useless (unless you want to fix bugs in lme4)."  There  
>>>> are
>>>> many other good uses to them, at least I have not fixed a single  
>>>> bug.
>>>> Why the pejorative language--especially on this list?
>>>
>>> I should perhaps clarify that I was thinking mainly of the lme4
>>> vignettes, which are explicitly targeted at implementors.  (If you
>>> have used them for other purposes, then I'd honestly love to know
>>> what.)  I see on CRAN that the help pages are also available as a  
>>> PDF,
>>> and the help pages are definitely valuable to end-users as a
>>> reference, but... they don't even document how to write an lmer
>>> formula.  Obviously this will be fixed sooner or later when someone
>>> has the time, and fortunately we have the other documents mentioned
>>> above (also mostly authored or co-authored by Doug) to cover the gap
>>> until then -- but for now they're not trivial to find.
>>>
>>> My intention wasn't to be pejorative, but simply to provide clear  
>>> and
>>> honest information about which documentation was currently useful  
>>> for
>>> which purposes.  But I do apologize if my flippant way of doing that
>>> offended anyone.
>
>> I have to disagree with your assessment of the vignettes.  The
>> documents do contain a lot of theory, but chapters 1-4 of
>> Implementation.pdf do an excellent job of describing varying types of
>> data to be fit using mixed models, how to fit the models using lmer,
>> and the structure of the fitted objects returned.  I see those
>> examples as far from 'useless'.  What exactly are you looking for?
>> One way you might find what you're looking for is to google:
>
>> "lmer" mixed filetype:pdf
>
>> or
>
>> lmer mixed filetype:pdf
>
>> The later (without the quotes) will lead to many documents on lme as
>> well as lmer
>
>> Also, although written prior to lmer, Pinheiro and Bates 2000 is  
>> still
>> an excellent resource.  Although I have limited experience with lmer,
>> for many models it seems the only difference for a useR to specify a
>> model in lme vs lmer is that the random argument from lme is removed
>> and the value for the argument is put in parentheses and moved into
>> the model formula.  For example:
>
>> lme(score ~ Machine, data = Machines, random= ~ 0 + Machine|Woker)
>
>> vs
>
>> lmer(score ~ Machine + (0 + Machine|Worker), data = Machines)
>
>> This not the case when fitting models with crossed random effects,
>> where in lme the random arugment took a somewhat convoluted list, but
>> in lmer the formulas are straightforward.
>
>> Finally, I'd like to point out that sending an email to this list is
>> essentially the same as sending one directly to Doug Bates, who I
>> think deserves our gratitude for his tremendous contributions to  
>> the R
>> community, and to the advancement of mixed modeling.
>
> Thanks for offering to save my feelings.  However, having survived two
> children going through their teenage years, being regarded as somewhat
> useless (not to mention a trifle dim-witted) is not a new experience
> for me. :-)
>
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models




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