@@ -3801,7 +3801,7 @@ def boxplot(self, x, notch=None, sym=None, vert=None, whis=None,
3801
3801
in *x*. If a sequence of 1D arrays, a boxplot is drawn for each
3802
3802
array in *x*.
3803
3803
3804
- notch : bool, default: False
3804
+ notch : bool, default: :rc:`boxplot.notch`
3805
3805
Whether to draw a notched boxplot (`True`), or a rectangular
3806
3806
boxplot (`False`). The notches represent the confidence interval
3807
3807
(CI) around the median. The documentation for *bootstrap*
@@ -3823,7 +3823,7 @@ def boxplot(self, x, notch=None, sym=None, vert=None, whis=None,
3823
3823
the fliers. If `None`, then the fliers default to 'b+'. More
3824
3824
control is provided by the *flierprops* parameter.
3825
3825
3826
- vert : bool, default: True
3826
+ vert : bool, default: :rc:`boxplot.vertical`
3827
3827
If `True`, draws vertical boxes.
3828
3828
If `False`, draw horizontal boxes.
3829
3829
@@ -3880,7 +3880,7 @@ def boxplot(self, x, notch=None, sym=None, vert=None, whis=None,
3880
3880
The widths of the boxes. The default is 0.5, or ``0.15*(distance
3881
3881
between extreme positions)``, if that is smaller.
3882
3882
3883
- patch_artist : bool, default: False
3883
+ patch_artist : bool, default: :rc:`boxplot.patchartist`
3884
3884
If `False` produces boxes with the Line2D artist. Otherwise,
3885
3885
boxes are drawn with Patch artists.
3886
3886
@@ -3897,7 +3897,7 @@ def boxplot(self, x, notch=None, sym=None, vert=None, whis=None,
3897
3897
75th percentiles are equal, *whis* is set to (0, 100) such
3898
3898
that the whisker ends are at the minimum and maximum of the data.
3899
3899
3900
- meanline : bool, default: False
3900
+ meanline : bool, default: :rc:`boxplot.meanline`
3901
3901
If `True` (and *showmeans* is `True`), will try to render the
3902
3902
mean as a line spanning the full width of the box according to
3903
3903
*meanprops* (see below). Not recommended if *shownotches* is also
@@ -3932,13 +3932,13 @@ def boxplot(self, x, notch=None, sym=None, vert=None, whis=None,
3932
3932
3933
3933
Other Parameters
3934
3934
----------------
3935
- showcaps : bool, default: True
3935
+ showcaps : bool, default: :rc:`boxplot.showcaps`
3936
3936
Show the caps on the ends of whiskers.
3937
- showbox : bool, default: True
3937
+ showbox : bool, default: :rc:`boxplot.showbox`
3938
3938
Show the central box.
3939
- showfliers : bool, default: True
3939
+ showfliers : bool, default: :rc:`boxplot.showfliers`
3940
3940
Show the outliers beyond the caps.
3941
- showmeans : bool, default: False
3941
+ showmeans : bool, default: :rc:`boxplot.showmeans`
3942
3942
Show the arithmetic means.
3943
3943
capprops : dict, default: None
3944
3944
The style of the caps.
@@ -3959,6 +3959,7 @@ def boxplot(self, x, notch=None, sym=None, vert=None, whis=None,
3959
3959
3960
3960
See Also
3961
3961
--------
3962
+ .Axes.bxp : Draw a boxplot from pre-computed statistics.
3962
3963
violinplot : Draw an estimate of the probability density function.
3963
3964
"""
3964
3965
@@ -4084,13 +4085,26 @@ def bxp(self, bxpstats, positions=None, widths=None, vert=True,
4084
4085
meanline = False , manage_ticks = True , zorder = None ,
4085
4086
capwidths = None ):
4086
4087
"""
4087
- Drawing function for box and whisker plots.
4088
+ Draw a box and whisker plot from pre-computed statistics.
4089
+
4090
+ The box extends from the first quartile *q1* to the third
4091
+ quartile *q3* of the data, with a line at the median (*med*).
4092
+ The whiskers extend from *whislow* to *whishi*.
4093
+ Flier points are markers past the end of the whiskers.
4094
+ See https://en.wikipedia.org/wiki/Box_plot for reference.
4095
+
4096
+ .. code-block:: none
4097
+
4098
+ whislow q1 med q3 whishi
4099
+ |-----:-----|
4100
+ o |--------| : |--------| o o
4101
+ |-----:-----|
4102
+ flier fliers
4088
4103
4089
- Make a box and whisker plot for each column of *x* or each
4090
- vector in sequence *x*. The box extends from the lower to
4091
- upper quartile values of the data, with a line at the median.
4092
- The whiskers extend from the box to show the range of the
4093
- data. Flier points are those past the end of the whiskers.
4104
+ .. note::
4105
+ This is a low-level drawing function for when you already
4106
+ have the statistical parameters. If you want a boxplot based
4107
+ on a dataset, use `~.Axes.boxplot` instead.
4094
4108
4095
4109
Parameters
4096
4110
----------
@@ -4170,9 +4184,9 @@ def bxp(self, bxpstats, positions=None, widths=None, vert=True,
4170
4184
- ``fliers``: points representing data beyond the whiskers (fliers).
4171
4185
- ``means``: points or lines representing the means.
4172
4186
4173
- Examples
4187
+ See Also
4174
4188
--------
4175
- .. plot:: gallery/ statistics/bxp.py
4189
+ boxplot : Draw a boxplot from data instead of pre-computed statistics.
4176
4190
"""
4177
4191
# Clamp median line to edge of box by default.
4178
4192
medianprops = {
@@ -8276,6 +8290,10 @@ def violinplot(self, dataset, positions=None, vert=True, widths=0.5,
8276
8290
to identify the quantile values of each of the violin's
8277
8291
distribution.
8278
8292
8293
+ See Also
8294
+ --------
8295
+ .Axes.violin : Draw a violin from pre-computed statistics.
8296
+ boxplot : Draw a box and whisker plot.
8279
8297
"""
8280
8298
8281
8299
def _kde_method (X , coords ):
@@ -8296,7 +8314,7 @@ def _kde_method(X, coords):
8296
8314
def violin (self , vpstats , positions = None , vert = True , widths = 0.5 ,
8297
8315
showmeans = False , showextrema = True , showmedians = False ):
8298
8316
"""
8299
- Drawing function for violin plots .
8317
+ Draw a violin plot from pre-computed statistics .
8300
8318
8301
8319
Draw a violin plot for each column of *vpstats*. Each filled area
8302
8320
extends to represent the entire data range, with optional lines at the
@@ -8378,6 +8396,11 @@ def violin(self, vpstats, positions=None, vert=True, widths=0.5,
8378
8396
- ``cquantiles``: A `~.collections.LineCollection` instance created
8379
8397
to identify the quantiles values of each of the violin's
8380
8398
distribution.
8399
+
8400
+ See Also
8401
+ --------
8402
+ violin :
8403
+ Draw a violin plot from data instead of pre-computed statistics.
8381
8404
"""
8382
8405
8383
8406
# Statistical quantities to be plotted on the violins
0 commit comments