Skip to content

Commit dce4836

Browse files
committed
Clarify behavior of prune parameter to MaxNLocator.
1 parent 3c56987 commit dce4836

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

lib/matplotlib/ticker.py

+5-7
Original file line numberDiff line numberDiff line change
@@ -1996,13 +1996,11 @@ def __init__(self, nbins=None, **kwargs):
19961996
If True, autoscaling will result in a range symmetric about zero.
19971997
19981998
prune : {'lower', 'upper', 'both', None}, default: None
1999-
Remove edge ticks -- useful for stacked or ganged plots where
2000-
the upper tick of one axes overlaps with the lower tick of the
2001-
axes above it, primarily when :rc:`axes.autolimit_mode` is
2002-
``'round_numbers'``. If ``prune=='lower'``, the smallest tick will
2003-
be removed. If ``prune == 'upper'``, the largest tick will be
2004-
removed. If ``prune == 'both'``, the largest and smallest ticks
2005-
will be removed. If *prune* is *None*, no ticks will be removed.
1999+
Remove the 'lower' tick, the 'upper' tick, or ticks on 'both' sides
2000+
*if they fall exactly on an axis' edge* (this typically occurs when
2001+
:rc:`axes.autolimit_mode` is 'round_numbers'). Removing such ticks
2002+
is mostly useful for stacked or ganged plots, where the upper tick
2003+
of an axes overlaps with the lower tick of the axes above it.
20062004
20072005
min_n_ticks : int, default: 2
20082006
Relax *nbins* and *integer* constraints if necessary to obtain

0 commit comments

Comments
 (0)