@@ -836,7 +836,11 @@ def label_minor(self, labelOnlyBase):
836
836
"""
837
837
Switch minor tick labeling on or off.
838
838
839
- ``labelOnlyBase=True`` to turn off minor ticks.
839
+ Parameters
840
+ ----------
841
+ labelOnlyBase : bool, optional, default: True
842
+ If True, only label decades.
843
+
840
844
"""
841
845
self .labelOnlyBase = labelOnlyBase
842
846
@@ -878,7 +882,7 @@ def set_locs(self, locs):
878
882
879
883
def __call__ (self , x , pos = None ):
880
884
"""
881
- Return the format for tick val `x` at position `pos` .
885
+ Return the format for tick val `x`.
882
886
"""
883
887
b = self ._base
884
888
if x == 0.0 :
@@ -960,8 +964,6 @@ class LogFormatterExponent(LogFormatter):
960
964
def __call__ (self , x , pos = None ):
961
965
"""
962
966
Return the format for tick value `x`.
963
-
964
- The position `pos` is ignored.
965
967
"""
966
968
vmin , vmax = self .axis .get_view_interval ()
967
969
vmin , vmax = mtransforms .nonsingular (vmin , vmax , expander = 0.05 )
@@ -1068,11 +1070,11 @@ def _non_decade_format(self, sign_string, base, fx, usetex):
1068
1070
if is_close_to_int (coeff ):
1069
1071
coeff = nearest_long (coeff )
1070
1072
if usetex :
1071
- return (r'$%g\times%s^{%d}$' ) % \
1072
- (coeff , base , exponent )
1073
+ return (r'$%s% g\times%s^{%d}$' ) % \
1074
+ (sign_string , coeff , base , exponent )
1073
1075
else :
1074
- return ('$%s$' % _mathdefault (r'%g\times%s^{%d}' %
1075
- (coeff , base , exponent )))
1076
+ return ('$%s$' % _mathdefault (r'%s% g\times%s^{%d}' %
1077
+ (sign_string , coeff , base , exponent )))
1076
1078
1077
1079
1078
1080
class LogitFormatter (Formatter ):
0 commit comments