[R] Stepwise in lme

Ben Bolker bbolker at gmail.com
Thu Dec 22 14:53:22 CET 2011


Pablo <pschatfield <at> gmail.com> writes:

> 
> I'm manually doing a form of stepwise regression in a mixed model but with
> many variables, it is time consuming.  I thought I'd try to use an automated
> approach.  stepAIC gave me false convergence when I used it with my model,
> so I thought it can't be hard to set up a basic program to do it based on
> the p-values.  Thus I tried a couple of (very) crude options:
> 
  [snip]
> 
> Hmm, perhaps I should abandon such abominations ... does anyone have some
> advice on how I might get such a crude method working or must I turn back
> and fight with stepAIC?
> 

  As with most mixed model questions, you might be better off re-posting
this to the r-sig-mixed-models at r-project.org mailing list ...

  I suspect you won't do much better than stepAIC.  I suspect that
the "false convergence" problem you're running into is not a function
of stepAIC itself, but that one of the sub-models you're trying to run
hits a false-convergence problem in lme itself -- that is, it won't
matter what your stepwise framework looks like, you'll still have to
run that model.

  You could also try the dredge() function in the MuMIn package (I'm
not sure about the capitalization -- maybe MuMin?)

   Ben Bolker



More information about the R-help mailing list