8000 Fix subplot docstring to show current behavior · matplotlib/matplotlib@d23af0d · GitHub
[go: up one dir, main page]

Skip to content

Commit d23af0d

Browse files
committed
Fix subplot docstring to show current behavior
1 parent bc68ad1 commit d23af0d

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

lib/matplotlib/pyplot.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1450,15 +1450,13 @@ def subplot(*args, **kwargs) -> Axes:
14501450
14511451
Notes
14521452
-----
1453-
Creating a new Axes will delete any preexisting Axes that
1454-
overlaps with it beyond sharing a boundary::
1453+
Creating a new Axes will not delete any preexisting Axes, even if they overlap::
14551454
14561455
import matplotlib.pyplot as plt
14571456
# plot a line, implicitly creating a subplot(111)
14581457
plt.plot([1, 2, 3])
14591458
# now create a subplot which represents the top plot of a grid
1460-
# with 2 rows and 1 column. Since this subplot will overlap the
1461-
# first, the plot (and its Axes) previously created, will be removed
1459+
# with 2 rows and 1 column. The existing plot (and its Axes) will remain
14621460
plt.subplot(211)
14631461
14641462
If you do not want this behavior, use the `.Figure.add_subplot` method

0 commit comments

Comments
 (0)
0