Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to specify quantile values for the whiskers of boxplots #449

Open
cristobaltapia opened this issue Jun 15, 2021 · 6 comments
Open

Comments

@cristobaltapia
Copy link

Hi, I am a rather new user of StatsPlots.jl and Julia. Thanks a lot for this package! I was doing some boxplots where I would like to mark the whiskers at the 5% and 95% quantile values. However, I could not find a way to do so. Reading through the implementation it looks like it is only possible to define the range value. Would it be possible to allow to overload range so that it also accepts a tuple of values e.g. (0.05, 0.95) and use it to draw the whiskers instead if IQR * range? Or maybe accept a tuple of any two arbitrary values that should be used for the whiskers?

Thanks!

@BeastyBlacksmith
Copy link
Member

BeastyBlacksmith commented Jun 15, 2021

Is #440 implementing what you are looking for?

@cristobaltapia
Copy link
Author

@BeastyBlacksmith yes! That is exactly what I was looking for. Hopefully it will get merged soon.

@cristobaltapia
Copy link
Author

I just tested this PR but it is not quite what I was looking for. What #440 implements is to modify the range of the box and add additional lines within the box, but what I would like to have is the possibility to define a custom value (or percentile) for the whiskers, i.e. the lines extending beyond the box.

@BeastyBlacksmith
Copy link
Member

That might be what was in #401 which @HenriDeh closed for some reason

@HenriDeh
Copy link
Contributor

HenriDeh commented Jun 16, 2021

I closed because I got no reaction to the PR and I'm not using StatPlots anymore. I can reopen if you like, or you can make a new PR and copy the changes of #401 that you want.

@cristobaltapia
Copy link
Author

I actually implemented a solution myself in the meantime. I like #401, however I think that it would be better to allow to specify the upper and lower quantiles for the whiskers independently (as done in matplotlib). However, to be honest, I have never used non-symmetric quantiles for this, so I don't know if this is really necessary. But since it is so defined in matplotlib, then there might be a use for it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants