Skip to content

Commit 0bde03a

Browse files
committed
fix some anntzer's comments
1 parent a9af431 commit 0bde03a

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

lib/matplotlib/tests/test_ticker.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -612,7 +612,7 @@ def test_params(self, input, expected):
612612

613613
# Test several non default separators: no separator, a narrow
614614
# no-break space (unicode character) and an extravagant string.
615-
for _sep in ("", "\u202f", "@_@"):
615+
for _sep in ("", "\N{NARROW NO-BREAK SPACE}", "@_@"):
616616
# Case 2: unit=UNIT and sep=_sep.
617617
# Replace the default space separator from the reference case
618618
# with the tested one `_sep` and append a unit symbol to it.

lib/matplotlib/ticker.py

+5-2
Original file line numberDiff line numberDiff line change
@@ -1218,7 +1218,10 @@ def __init__(self, unit="", places=None, sep=" "):
12181218
Precision with which to display the number, specified in
12191219
digits after the decimal point (there will be between one
12201220
and three digits before the decimal point). If it is None,
1221-
falls back to the floating point format '%g'.
1221+
the formatting falls back to the floating point format '%g',
1222+
which displays up to 6 *significant* digits (i.e. the
1223+
equivalent value for *places* varies between 0 and 5, both
1224+
values included).
12221225
12231226
sep : str (default: " ")
12241227
Separator used between the value and the prefix/unit. For
@@ -1258,7 +1261,7 @@ def format_eng(self, num):
12581261
u'-1.00 \N{GREEK SMALL LETTER MU}'
12591262
12601263
`num` may be a numeric value or a string that can be converted
1261-
to a numeric value with `float(num)`.
1264+
to a numeric value with ``float(num)``.
12621265
"""
12631266
dnum = float(num)
12641267
sign = 1

0 commit comments

Comments
 (0)