[R-sig-ME] random regression with MCMCglmm

Jarrod Hadfield j.hadfield at ed.ac.uk
Thu Jun 24 10:24:43 CEST 2010


Hi Celine,

The most likely reason is that Cat or st2Food are not present in your  
data frame.  If this is not the case, then let me know and I'll take a  
more detailed look.

Cheers,

Jarrod


On 23 Jun 2009, at 16:07, Celine Teplitsky wrote:

> Dear all,
>
> I would like to fit a random regression using MCMCglmm. The problem  
> is I don't manage to include heterogeneous residual variance (when I  
> use just one residual variance the model is running). I have created  
> a factor (Cat) grouping the environments into 4 food qualities from  
> good to bad, so the model looks like:
> priorA<-list(G=list(G1=list(V=diag(2), n=2)),R=list(V=diag(4), n= 2))
>
> MCMCglmm(LD ~ Age+stFood , random=~us(1+st2Food):ID, rcov =  
> ~us(Cat):units, data=Data,prior=priorA, family =  
> c("gaussian"),nitt=120000, burnin=20000, thin=100)
>
> but I get this error message, and I really don't know how to fix the  
> problem:
>
> Error in `[.data.frame`(data, , components[[1]]) :
>  undefined columns selected
>
> Many thanks in advance for any help
>
> Celine
>
> -- 
>
> Celine Teplitsky
> Département Ecologie et Gestion de la Biodiversité UMR 7204
> Unité Conservation des Espèces, Restauration et Suivi des Populations
> Case Postale 51
> 55 rue Buffon 75005 Paris
>
> Webpage : http://www2.mnhn.fr/cersp/spip.php?rubrique96
> Fax : (33-1)-4079-3835
> Phone: (33-1)-4079-3443
>
> _______________________________________________
> 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