Skip to content

Commit 3d1c293

Browse files
committed
simplify test for range of steps
1 parent 4bb7b6f commit 3d1c293

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/ticker.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1693,7 +1693,7 @@ def _validate_steps(steps):
16931693
steps = np.asarray(steps)
16941694
if np.any(np.diff(steps) <= 0):
16951695
raise ValueError('steps argument must be uniformly increasing')
1696-
if np.any((steps > 10) | (steps < 1)):
1696+
if steps[-1] > 10 or steps[0] < 1:
16971697
warnings.warn('Steps argument should be a sequence of numbers\n'
16981698
'increasing from 1 to 10, inclusive. Behavior with\n'
16991699
'values outside this range is undefined, and will\n'

0 commit comments

Comments
 (0)