MCMCglmm bivariate with offset
Thank you Jarrod, the model finally ran with your advice. I am aware of the sensitivity of the posterior distribution, this is just my first prior. I am going to use another one with nu = 1.002. Cheers Walid
On 6/13/2018 2:08 PM, HADFIELD Jarrod wrote:
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 at 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 at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
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