[R-sig-ME] BLUPs from MCMCglmm

Jarrod Hadfield j.hadfield at ed.ac.uk
Thu Jan 19 12:34:43 CET 2012


The random effects are actually stored in Sol (solutions) and will be  
saved if you use the argument pr=TRUE.  The marginal posterior modes  
of the random effects should coincide with BLUPs if the variances are  
fixed a priori to the value used when obtaining BLUPs and the fixed  
effects are either fixed a priori or are given improper flat priors.  
However, in practice (i.e. when the variances are not fixed etc.) the  
correlation between BLUPs and marginal posterior modes is usually very  
very high.

Be aware that if you have many (m) random effects and you store many  
(n) iterations you end up with a lot (m*n) of numbers  to store.



On 18 Jan 2012, at 14:51, Ben Bolker wrote:

> Eryn McFarlane <mcfarlas at ...> writes:
>> Dear list,
>> I was wondering if anyone knew of a way to estimate BLUPs
>> from an MCMCglmm model? I would just like to eyeball
>> the individuals with high and low BLUPs for my trait to
>> see if there are other relationships that I can see
>> (i.e. year effects, affect of territory). Does this make sense to  
>> try to do
> from these models?
>  I *think* you can just look at the $Liab component of the fit,
> which as stated is the posterior distribution of the latent  
> variables --
> you need to set pl=TRUE.
>  This should get you started (although HPDinterval() isn't
> behaving sensibly in this case -- not quite sure why not)
> data(PlodiaPO)
>     model1<-MCMCglmm(PO~1, random=~FSfamily, data=PlodiaPO,
>    verbose=FALSE, pl=TRUE)
> str(model1$Liab)
> mm <- data.frame(m=colMeans(model1$Liab),HPDinterval(model1$Liab))
> plot(mm[order(mm$m),"m")
> _______________________________________________
> 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