Skip to content
Back to formatted view

Raw Message

Message-ID: <20140304120705.21091rcjyfy7gs74@www.staffmail.ed.ac.uk>
Date: 2014-03-04T12:07:05Z
From: Jarrod Hadfield
Subject: MCMCglmm variance estimates Poisson distribution
In-Reply-To: <fccb672635fe43ca80fee6325436cdd5@AM3PR03MB563.eurprd03.prod.outlook.com>

Dear John,

How are you calculating the posterior expectation:

1/
posterior.mode(exp(mcmc.c11.cf2$Sol+mcmc.c11.cf2$VCV/2))
2/
mean(exp(mcmc.c11.cf2$Sol+mcmc.c11.cf2$VCV/2))
3/
exp(posterior.mode(mcmc.c11.cf2$Sol)+posterior.mode(mcmc.c11.cf2$VCV/2))
4/
exp(mean(mcmc.c11.cf2$Sol)+mean(mcmc.c11.cf2$VCV/2))

If it is not by method 1/ try that and see if there is less of a discrepancy.

Cheers,

Jarrod

Quoting "Hodsoll, John" <john.hodsoll at kcl.ac.uk> on Tue, 4 Mar 2014  
11:25:17 +0000:

> Dear list
>
> I'm trying to get some unadjusted estimates and 95% CI for a set of  
> correlated count data (due to repeated measures on the same cluster)  
> . To do this I was trying to run an over-dispersed poisson model  
> using a glmer and MCMCglmm.
>
> I want to use MCMCglmm as that's the package I wish to use for my  
> main analysis. However, it seems to over-estimate the variance  
> meaning that the mean value I get from the intercept only model y =  
> XB + Var/2 (ch2 jarrod hadfield's course notes) is slightly greater  
> than the actual mean. For example, if I fit the model
>
> priortr <- list(R=list(V=1, nu=0.001))
>
> mcmc.c11.cf2 <- MCMCglmm(totflct ~ 1, family="poisson", prior =  
> priortr, data=uc11,
>                          nitt = 100000, burnin = 10000, thin = 90)
> summary(mcmc.c11.cf2)
>
> I'm ignoring the random effect and assuming the additive  
> over-dispersion term will capture all the extra variance. For a  
> count rate of 4.69 in the data I get 4.79 and for a count of 5.2 I  
> get 5.52. On the other hand, if I use glmer including a per  
> observation random effect I get the correct means
>
> re.uc12.cf <- glmer(totflct ~ (1|obs), family=poisson, data=uc12)
> summary(re.uc12.cf)?
>
> Is there something I missing here?
>
> Regards
> John Hodsoll
>
> _______________________________________________
> 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.