2
$\begingroup$

I've created violin plots of my data and included quantile lines. These were created with the geom_violin function from ggplot2 in R. However, I realized that these quantiles differed from the ones I get when I calculate them myself with the quantile function. After some investigation I found out that geom_violin seems to determine quantiles based on density rather than the raw data (see here). So my question is, why generate quantiles in this way rather than based on the raw data? Are there times when one method is preferable to the other?

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.