I'm trying to do a boxplot with ggplot function : ggplot() + geom_boxplot(...)
how is the whisker calculated with ggplot?
This is answered on the ?geom_boxplot
help page:
The upper whisker extends from the hinge to the largest value no further than 1.5 * IQR from the hinge (where IQR is the inter-quartile range, or distance between the first and third quartiles). The lower whisker extends from the hinge to the smallest value at most 1.5 * IQR of the hinge. Data beyond the end of the whiskers are called "outlying" points and are plotted individually.
(From my version 2.2.1. Find the current docs here: http://ggplot2.tidyverse.org/reference/geom_boxplot.html, or the docs for whatever version you are using at ?geom_boxplot
.)
If you have questions about the hinge, see the preceding paragraph on the help page.