Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 19baac5

Browse files
committed
Modified to blacklist log scale for AutoMinorLocator
1 parent cb5042d commit 19baac5

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

lib/matplotlib/ticker.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1938,8 +1938,9 @@ def __init__(self, n=None):
19381938

19391939
def __call__(self):
19401940
'Return the locations of the ticks'
1941-
if self.axis.get_scale() != 'linear':
1942-
warnings.warn('AutoMinorLocator only works with linear scale')
1941+
if self.axis.get_scale() == 'log':
1942+
warnings.warn('AutoMinorLocator does not work with logarithmic '
1943+
'scale')
19431944
return []
19441945

19451946
majorlocs = self.axis.get_majorticklocs()

0 commit comments

Comments
 (0)