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 c96334d

Browse filesBrowse files
committed
fix failing test
1 parent 2e41cb5 commit c96334d
Copy full SHA for c96334d

File tree

Expand file treeCollapse file tree

2 files changed

+3
-3
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+3
-3
lines changed

‎doc/users/next_whats_new/boxplot_legend_support.rst

Copy file name to clipboardExpand all lines: doc/users/next_whats_new/boxplot_legend_support.rst
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Legend support for Boxplot
33
Boxplots now support a *label* parameter to create legend entries.
44

55
Legend labels can be passed as a list of strings to label multiple boxes in a single
6-
`.boxplot` call:
6+
`.Axes.boxplot` call:
77

88

99
.. plot::
@@ -37,7 +37,7 @@ Legend labels can be passed as a list of strings to label multiple boxes in a si
3737
ax.legend()
3838

3939

40-
Or as a single string to each individual `.boxplot`:
40+
Or as a single string to each individual `.Axes.boxplot`:
4141

4242
.. plot::
4343
:include-source: true

‎lib/matplotlib/tests/test_legend.py

Copy file name to clipboardExpand all lines: lib/matplotlib/tests/test_legend.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1460,7 +1460,7 @@ def test_boxplot_legend_labels():
14601460
assert all(isinstance(h, mpl.lines.Line2D) for h in handles)
14611461

14621462
# Testing legend with number of labels different from number of boxes.
1463-
with pytest.raises(ValueError, match='There must be an equal number'):
1463+
with pytest.raises(ValueError, match='values must have same the length'):
14641464
bp3 = axs[2].boxplot(data, label=legend_labels[:-1])
14651465

14661466
# Test that for a string label, only the first box gets a label.

0 commit comments

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