[R-sig-ME] MCMCglmm bivariate with offset

HADFIELD Jarrod j@h@dfield @ending from ed@@c@uk
Wed Jun 13 20:08:09 CEST 2018


Hi, 

I think you have 11 fixed effects, not 5. Replace 5 with 11 and then it should work. Also, you should expect the posterior to be sensitive to the prior if you have nu=3 unless there is a lot of information in the data.

Cheers,

Jarrod


> On 13 Jun 2018, at 15:28, Walid Mawass <walidmawass10 using gmail.com> wrote:
> 
> Hello everyone,
> 
> I am working on a bivariate MCMCglmm model and I want to include an 
> offset term for my second response variable. I already know that for the 
> offset, i have to fix the coefficient to 1 through the prior but it is 
> not working in my case. I have 4 fixed effects fitted for both response 
> variables and the offset is fitted for the second one using 
> /at.level(trait,2)/.
> 
> prior1 <- list(B=list(V=diag(5)*1e8, mu=rep(0,5)), R=list(V=diag(2), 
> nu=3), G=list(G1=list(V=diag(2), nu=3),G2=list(V=diag(2), nu=3)))
> prior1$B$mu[5]<- 1
> prior1$B$V[5,5]<- 1e-8
> 
> is this the proper way to set the prior? or should the fixed effects 
> matrix have different dimensions since my model is bivariate:
> 
> model_multi <- MCMCglmm(cbind(AFR, OffMortality)~trait-1 + trait:COEFPAR 
> + trait:I(COEFPAR*COEFPAR) + trait:TWIN + trait:YEARM+ 
> at.level(trait,2):log(FERTILITY), random = 
> ~us(trait):animal+us(trait):MOTHERW, rcov = ~us(trait):units, data = 
> IAC, pedigree = prunedPed, family = c("gaussian", "poisson"), nitt = 
> 3500000, burnin = 500000, thin = 3000, prior = prior1, verbose = FALSE, 
> pr=TRUE)
> 
> Thank you in advance for any advice.
> 
> -- 
> Walid Mawass
> 
> Ph.D. candidate in Cellular and Molecular Biology
> 
> Population Genetics Laboratory
> 
> University of Québec at Trois-Rivières
> 3351, boul. des Forges, C.P. 500
> Trois-Rivières (Québec) G9A 5H7
> Telephone: 819-376-5011 poste 3384
> 
> 
> 	[[alternative HTML version deleted]]
> 
> _______________________________________________
> R-sig-mixed-models using 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