Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 4d390fa

Browse filesBrowse files
authored
Merge pull request matplotlib#7753 from Carreau/improve-whiskers-docstrings
Clarify the uses of whiskers float parameter.
2 parents d7879bc + 97609a8 commit 4d390fa
Copy full SHA for 4d390fa

File tree

Expand file treeCollapse file tree

2 files changed

+12
-6
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+12
-6
lines changed

‎lib/matplotlib/axes/_axes.py

Copy file name to clipboardExpand all lines: lib/matplotlib/axes/_axes.py
+6-3Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3128,9 +3128,12 @@ def boxplot(self, x, notch=None, sym=None, vert=None, whis=None,
31283128
everything is drawn horizontally.
31293129
31303130
whis : float, sequence, or string (default = 1.5)
3131-
As a float, determines the reach of the whiskers past the
3132-
first and third quartiles (e.g., Q3 + whis*IQR,
3133-
IQR = interquartile range, Q3-Q1). Beyond the whiskers, data
3131+
As a float, determines the reach of the whiskers to the beyond the
3132+
first and third quartiles. In other words, where IQR is the
3133+
interquartile range (`Q3-Q1`), the upper whisker will extend to
3134+
last datum less than `Q3 + whis*IQR`). Similarly, the lower whisker
3135+
will extend to the first datum greater than `Q1 - whis*IQR`.
3136+
Beyond the whiskers, data
31343137
are considered outliers and are plotted as individual
31353138
points. Set this to an unreasonably high value to force the
31363139
whiskers to show the min and max values. Alternatively, set

‎lib/matplotlib/cbook.py

Copy file name to clipboardExpand all lines: lib/matplotlib/cbook.py
+6-3Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1872,9 +1872,12 @@ def boxplot_stats(X, whis=1.5, bootstrap=None, labels=None,
18721872
fewer dimensions.
18731873
18741874
whis : float, string, or sequence (default = 1.5)
1875-
As a float, determines the reach of the whiskers past the first
1876-
and third quartiles (e.g., Q3 + whis*IQR, QR = interquartile
1877-
range, Q3-Q1). Beyond the whiskers, data are considered outliers
1875+
As a float, determines the reach of the whiskers to the beyond the
1876+
first and third quartiles. In other words, where IQR is the
1877+
interquartile range (`Q3-Q1`), the upper whisker will extend to last
1878+
datum less than `Q3 + whis*IQR`). Similarly, the lower whisker will
1879+
extend to the first datum greater than `Q1 - whis*IQR`.
1880+
Beyond the whiskers, data are considered outliers
18781881
and are plotted as individual points. This can be set this to an
18791882
ascending sequence of percentile (e.g., [5, 95]) to set the
18801883
whiskers at specific percentiles of the data. Finally, `whis`

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.