[R-sig-ME] Calcul of confidence intervals of estimate coefficient by a logistic regression with random effect
Ben Bolker
bbolker at gmail.com
Fri Oct 11 22:18:31 CEST 2013
Laetitia ETIENNE <laetitia.etienne at ...> writes:
>
> Hello,
> I would like to know how can i calculate confidence intervals of
> coefficients estimate with a logistic regression with random effect
> (i use the lme4 package for my glmm) ?
> Example:
>
> > y<-cbind(total-morts,morts)
>
> > library(lme4)
> > modF<-glmer(y~sppNB+Fmyc+(1|Bloc),family=binomial(link="logit"))
> > drop1(modF,test="Chisq")
[snip]
> > summary(modF)
> Bloc (Intercept) 0.31936 0.56512
> Number of obs: 15, groups: Bloc, 3
[snip]
> I would like to know the confidence interval of the estimate coefficent
> of "Fmyc".
If you're using the current (1.0-4) version of lme4, then
the answer is "?confint.merMod"; that gives you options of
profile confidence intervals (default: possibly slow but
fairly accurate); Wald intervals (fastest and least accurate);
or parametric bootstrap intervals (slowest and most accurate).
You can speed things up a bit by specifying the 'which' argument
so that you only profile the parameters you actually care about,
but you need to know the position in the complete parameter
vector (including random effect parameters) -- this is something
we should improve in the future. I think in this case it would
be which(names(fixef(modF))=="Fmyc")+1 since there is one
random effects parameter.
By the way, I worry that your model is overparameterized --
15 observations is very few to estimate 5 fixed effect parameters and
1 random effect parameter, and 3 levels is very few for estimating
a random effect. Rules of thumb are >=5 levels for estimating a
random effect, and 10-20 observations per parameter ...
More information about the R-sig-mixed-models
mailing list