AndriSignorell/DescTools

CoefVar() does not compute confidence interval limits

mae-irgendwas opened this issue · 2 comments

Hello!

I'm using the CoefVar function in R version 4.2.2, DescTools version 0.99.47.
It correctly calculates the coefficient of variation, but gives NA as confidence interval limits. This is true also for the example from the example in the R Documentation:

set.seed(15)
x <- runif(100)
CoefVar(x, conf.level=0.95)
est low.ci upr.ci
0.5092566 NA NA

Thank you for your help in advance!

This has been fixed. Please use the new function CoefVarCI() for calculating the confidence intervals. There are several implemented methods available, although there's one more on the bucket list.

set.seed(15)
x <- runif(100)
CoefVarCI(CoefVar(x), length(x), conf.level=0.95)
           est    lwr.ci    upr.ci
[1,] 0.5092566 0.4351644 0.6151409

Thank you for fixing the problem and implementing different options!