Coefficient of Quartile Variation

Coefficient of quartile variation ($$CQV$$) is a measure of relative dispersion that is based on interquartile range (IQR). Since cqv is unitless, it is useful for comparison of variables with different units. It is also a measure of homogeneity (Altunkaynak & Gamgam, 2018; Bonett, 2006).
The population coefficient of quartile variation is:
$CQV = \biggl(\frac{Q_3-Q_1}{Q_3+Q_1}\biggr)\times100$ where $$q_3$$ and $$q_1$$ are the population third quartile (i.e., $$75^{th}$$ percentile) and first quartile (i.e., $$25^{th}$$ percentile), respectively. Almost always, we analyze data from samples but want to generalize it as the population’s parameter (Albatineh, Kibria, Wilcox, & Zogheib, 2014). Its sample’s estimate is given as:
$cqv = \biggl(\frac{q_3-q_1}{q_3+q_1}\biggr)\times100$ There are different methods for the calculation of confidence intervals (CI) for CQV. All of them are fruitful and have particular use cases. For sake of versatility, we cover almost all of these methods in cvcqv package. Here, we explain them along with some examples:

Bonett Confidence Interval

Bonett (Bonett, 2006) introduced the following confidence interval for CQV:
$\exp\{\ln{(D/S)c\ \pm\ Z_{1-\alpha/2}\sqrt{v} }\}$ where $$c = n/(n-1)$$ is a centering adjustment which helps to equalize the tail error probabilities (Altunkaynak & Gamgam, 2018; Bonett, 2006). $$D = \hat{Q3}-\hat{Q1}$$ and $$S = \hat{Q3}+\hat{Q1}$$ are the sample $$25^{th}$$ and $$75^{th}$$ percentiles, respectively; $$Z_{1-\alpha/2}$$ is the $$1-\alpha/2$$ quantile of the standard normal distribution. Computation of $$v$$ which is $$Var\{\ln{(D/S)}\}$$ is long and a bit complicated, but has been implemented for cqv function:

## $method ##  "cqv with Bonett 95% CI" ## ##$statistics
##      est  lower  upper
##   45.625 24.785 77.329

Bootstrap Confidence Intervals

Thanks to package boot (Canty & Ripley, 2017) we can obtain bootstrap CI around $$cqv$$:

## $method ##  "cqv with adjusted bootstrap percentile (BCa) 95% CI" ## ##$statistics
##      est  lower  upper
##   45.625 21.527 79.698

All Available Methods

In conclusion, we can observe CIs calculated by all available methods:

## $method ##  "All methods" ## ##$statistics
##            est  lower  upper
## bonett  45.625 24.785 77.329
## norm    45.625 19.410 70.462
## basic   45.625 19.398 73.303
## percent 45.625 17.947 71.852
## bca     45.625 25.532 83.405
##                                                 description
## bonett                               cqv with Bonett 95% CI
## norm                   cqv with normal approximation 95% CI
## basic                       cqv with basic bootstrap 95% CI
## percent                cqv with bootstrap percentile 95% CI
## bca     cqv with adjusted bootstrap percentile (BCa) 95% CI