Skip to content

Commit 0b5a9b2

Browse files
committed
Format MaxNLocator with numpydoc
1 parent dba2d7b commit 0b5a9b2

File tree

1 file changed

+11
-13
lines changed

1 file changed

+11
-13
lines changed

lib/matplotlib/ticker.py

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1833,32 +1833,30 @@ class MaxNLocator(Locator):
18331833

18341834
def __init__(self, *args, **kwargs):
18351835
"""
1836-
Keyword args:
1837-
1838-
*nbins*
1836+
Parameters
1837+
----------
1838+
nbins : int or 'auto', optional, default: 10
18391839
Maximum number of intervals; one less than max number of
18401840
ticks. If the string `'auto'`, the number of bins will be
18411841
automatically determined based on the length of the axis.
18421842
1843-
*steps*
1843+
steps: array-like, optional
18441844
Sequence of nice numbers starting with 1 and ending with 10;
18451845
e.g., [1, 2, 4, 5, 10], where the values are acceptable
18461846
tick multiples. i.e. for the example, 20, 40, 60 would be
18471847
an acceptable set of ticks, as would 0.4, 0.6, 0.8, because
18481848
they are multiples of 2. However, 30, 60, 90 would not
18491849
be allowed because 3 does not appear in the list of steps.
18501850
1851-
*integer*
1851+
integer : bool, optional, default: False
18521852
If True, ticks will take only integer values, provided
18531853
at least `min_n_ticks` integers are found within the
18541854
view limits.
18551855
1856-
*symmetric*
1857-
If True, autoscaling will result in a range symmetric
1858-
about zero.
1856+
symmetric : bool, optional, default: False
1857+
If True, autoscaling will result in a range symmetric about zero.
18591858
1860-
*prune*
1861-
['lower' | 'upper' | 'both' | None]
1859+
prune : {'lower', 'upper', 'both', None}, optional, default: None
18621860
Remove edge ticks -- useful for stacked or ganged plots where
18631861
the upper tick of one axes overlaps with the lower tick of the
18641862
axes above it, primarily when :rc:`axes.autolimit_mode` is
@@ -1867,9 +1865,9 @@ def __init__(self, *args, **kwargs):
18671865
removed. If ``prune == 'both'``, the largest and smallest ticks
18681866
will be removed. If ``prune == None``, no ticks will be removed.
18691867
1870-
*min_n_ticks*
1871-
Relax `nbins` and `integer` constraints if necessary to
1872-
obtain this minimum number of ticks.
1868+
min_n_ticks : int, optional, default: 2
1869+
Relax *nbins* and *integer* constraints if necessary to obtain
1870+
this minimum number of ticks.
18731871
18741872
"""
18751873
if args:

0 commit comments

Comments
 (0)