[R-sig-ME] code for multiple membership models?

Jarrod Hadfield j.hadfield at ed.ac.uk
Tue Aug 7 10:20:07 CEST 2012


This is mainly a reply to Malcolm's earlier email which I had missed  
(I do field work from April-July and don't usually read emails).

To fit the MLWin multimembership model in MCMCglmm:

library(foreign); lips <-  

prior=list(R=list(V=1, nu=0), G=list(G1=list(V=1, nu=1, alpha.mu=0,  

random=~idv(~neigh1:weight1+neigh2:weight2+neigh3:weight3+neigh4:weight4+neigh5:weight5+neigh6:weight6+neigh7:weight7+neigh8:weight8+neigh9:weight9+neigh10:weight10+neigh11:weight11), data=lips, family="poisson",  

Unfortunately the book is no longer on their server so I can't compare  
the results. However, I find little evidence for area effects once  
observation level overdispersion is accounted for (default in  
MCMCglmm, but perhaps not fitted in the original analyses).

The next version of MCMCglmm will have more efficient ways of setting  
up multimembership models, and also related models which I don't know  
the name for. Perhaps someone does? For example, imagine you want to  
fit mother and grandmother as random effects for some trait measured  
in offspring. The usual model would be:


However, if some mothers appear as grandmothers the covariance between  
their effects is estimable and perhaps of interest.  The next version  
will make this possible as random=~str(~mother, ~gmother).



Quoting George Leckie <g.leckie at bristol.ac.uk> on Mon, 6 Aug 2012  
18:36:18 +0100:

> Dear Doug,
> I found your post on fitting multiple membership models using lme4a  
> very helpful
>     https://stat.ethz.ch/pipermail/r-sig-mixed-models/2011q2/006318.html
> and I managed to get this approach on my own data.
> I am now trying to follow the same approach on the new version of lme4
> as this is now meant to have superceded lme4a
>     http://lme4.r-forge.r-project.org/
> However, the approach no longer appears to work as the the noFit
> option appears not to be supported. It also no longer seems possible
> to edit the Zt matrices and so on.
> Might you be able to update your previous example to show us how to
> fit multiple membership models using the new lme4?
> I see that there have also been some recent posts about difficulties
> in manually editing Zt in other contexts, so perhaps this is general
> problem for lme4 which lme4a could deal with?
>     https://stat.ethz.ch/pipermail/r-sig-mixed-models/2012q2/018118.html
> Best wishes
> George
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models

The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.

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