[R-sig-ME] Announcing new version of afex (0.11-131)

Henrik Singmann henrik.singmann at psychologie.uni-freiburg.de
Mon Oct 13 15:23:18 CEST 2014

Dear list,

The latest version of afex (0.11-131), package for fitting ANOVAs and obtaining p-values in mixed models, was accepted on CRAN yesterday: http://cran.r-project.org/web/packages/afex/index.html

As discussed previously on this list, afex does *not* change the global contrast anymore, although mixed() and the ANOVA functions still use "contr.sum" per default (by changing the contrasts of the factors in the data.frame passed). To set contrasts globally use functions set_sum_contrasts() or set_default_contrasts().

The main new functionality is:
- added the allFit() function written by Ben Bolker which fits an (g)lmer model with all possible optimizers (see ?allFit or https://github.com/lme4/lme4/blob/master/misc/issues/allFit.R).
- mixed objects as returned from mixed() are now fully supported by lsmeans for post-hoc tests or plotting (lsmip).
- the ANOVA functions (i.e., aov.car, ez.glm, & aov4) return the ANOVA fitted with aov when return = "aov" which can also be passed to lsmeans (be careful with unbalanced designs).

The full NEWS is below:

                     Changes in afex Version 0.11-x
                     Released October 2014

     Significant User Visible Changes and New Features

     o   added allFit() function (written by Ben Bolker).
     o   mixed() gives warning if nested model provides worse fit
         (logLik) than full model (when fitted with ML).
     o   print, summary, and anova method for mixed objects are now
     o   description of returned object from mixed() extended (Thanks
         to Ben Bolker, see http://stackoverflow.com/a/25612960/289572)
     o   added return = "aov" to aov.car which returns the ANOVA
         fitted with aov (with correct Error strata) so that it can be
         passed to lsmeans for post-hoc tests or plotting (lsmip).
     o   all required functions are now correctly imported avoiding
         CRAN warnings and better functioning.
     o   data argument to lmer calls in mixed set correctly. Note that
         still contrasts added to the data in mixed may prohibit use of
         predict.merMod() or similar functions. It is recommended to
         set the contrasts globally to "contr.sum", e.g.,
         via set_sum_contrasts(), for correct functioning
         (disable via set.data.arg argument for mixed).

Dr. Henrik Singmann
Albert-Ludwigs-Universität Freiburg, Germany

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