diff --git a/lib/matplotlib/ticker.py b/lib/matplotlib/ticker.py index 1dcbfbc49b08..d740721b6c78 100644 --- a/lib/matplotlib/ticker.py +++ b/lib/matplotlib/ticker.py @@ -81,6 +81,19 @@ The default minor locator is `NullLocator`, i.e., no minor ticks on by default. +.. note:: + `Locator` instances should not be used with more than one + `~matplotlib.axis.Axis` or `~matplotlib.axes.Axes`. So instead of:: + + locator = MultipleLocator(5) + ax.xaxis.set_major_locator(locator) + ax2.xaxis.set_major_locator(locator) + + do the following instead:: + + ax.xaxis.set_major_locator(MultipleLocator(5)) + ax2.xaxis.set_major_locator(MultipleLocator(5)) + Tick formatting ---------------