[R-sig-ME] Confidence interval for sum of coefficients
Michael Cone
coanil at posteo.org
Thu Sep 25 14:40:54 CEST 2014
Dear Lorenz,
ah, thank you for pointing this out, I really should have read the list
more carefully. I will look into the relevant conversation.
Kind regards
Michael
Am 25.09.2014 14:35 schrieb lorenz.gygax at agroscope.admin.ch:
> Dear Michael,
>
> This is possibly not what you should do. As has been recently
> suggested to me on this list, you could use bootMer with a function
> that computes the sum(s) that you are interested in. Then use boot.ci
> from the boot package to estimate the confidence intervals
>
> Best wishes, Lorenz
>
>> -----Ursprüngliche Nachricht-----
>> Von: r-sig-mixed-models-bounces at r-project.org
>> [mailto:r-sig-mixed-models-
>> bounces at r-project.org] Im Auftrag von Michael Cone
>> Gesendet: Donnerstag, 25. September 2014 14:11
>> An: r-sig-mixed-models at r-project.org
>> Betreff: [R-sig-ME] Confidence interval for sum of coefficients
>>
>> Hello,
>>
>> I suspect this to be simple, but I can't figure it out.
>>
>> > library(lme4)
>> > data(Machines)
>> > fm1 <- lmer(score ~ Machine + (Machine | Worker), data = Machines)
>> > summary(fm1)
>> Fixed effects:
>> Estimate Std. Error t value
>> (Intercept) 52.356 1.681 31.151
>> MachineB 7.967 2.421 3.291
>> MachineC 13.917 1.540 9.036
>> > confint(fm1)
>> 2.5 % 97.5 %
>> [...]
>> (Intercept) 48.7964047 55.9147119
>> MachineB 2.8401623 13.0931789
>> MachineC 10.6552809 17.1780575
>>
>> [and 14 warnings, but it's just an example:
>> In optwrap(optimizer, par = start, fn = function(x) dd(mkpar(npar1,
>> ...
>> :
>> convergence code 1 from bobyqa: bobyqa -- maximum number of function
>> evaluations exceeded
>> ...
>> In profile.merMod(object, signames = oldNames, ...) : non-monotonic
>> profile]
>>
>> I'd like to have confidence intervals for the overall score of
>> MachineA,
>> MachineB, and MachineB. MachineA is easy (CI of the intercept), but
>> how
>> do I combine the CI of the intercept with the CI of the MachineB
>> parameter, and likewise the CI of the intercept with the parameter of
>> MachineC? Can I simply add the lower and upper bounds of the two
>> intervals or is this naive?
>>
>> Thank you for your time,
>>
>> Michael
>>
>> _______________________________________________
>> R-sig-mixed-models at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
More information about the R-sig-mixed-models
mailing list