[R-sig-ME] MCMCglmm bivariate with offset
Walid Mawass
w@lidm@w@@@10 @ending from gm@il@com
Wed Jun 13 16:28:51 CEST 2018
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]]
More information about the R-sig-mixed-models
mailing list