[R-sig-ME] MCMCglmm random intercept/slope model and credible intervals

Maya maiski at maiski.net
Mon Oct 7 14:52:06 CEST 2013


Hello all,

i have the following problem. 
I want to fit a GLMM with a numerical fixed effect, a factorial random
effect, containing subject ids and a binary outcome. My code is:

fam='categorical'

priors1<-list(R = list(V = 1, nu = 0.002), G = list(G1 = list(V = diag(2),
nu = 6)))

modelGlmm1<- MCMCglmm(toModel ~ fixedEffect,
random=~us(1+fixedEffect):randomEffect, data=data, verbose=FALSE,
family=fam, pr=TRUE, pl=TRUE, nitt=nittM, thin=thinM, burnin=burninM,
prior=priors1)

mp1 = predict(modelGlmm1, interval = 'confidence')


But as I try to get the credible intervals I get the following error:
Error in M[, which(rm.v), ] <- 0 : incorrect number of subscripts.

Could anybody give me some hints or enlighten me on the subject? I cannot
figure it out by myself :/

I have also another question: How are the credible intervals constructed:
pointwise or simultaniously?

Thanks in advance! 

Greets,

Maya



More information about the R-sig-mixed-models mailing list