File tree 4 files changed +10
-3
lines changed
4 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -110,6 +110,13 @@ did not have the same index as the input.
110
110
df.groupby(' a' , dropna = True ).transform(lambda x : x)
111
111
df.groupby(' a' , dropna = True ).transform(' sum' )
112
112
113
+ .. _whatsnew_150.notable_bug_fixes.visualization :
114
+
115
+ Styler
116
+ ^^^^^^
117
+
118
+ - Fix showing "None" as ylabel in :meth: `Series.plot ` when not setting ylabel (:issue: `46129 `)
119
+
113
120
.. _whatsnew_150.notable_bug_fixes.notable_bug_fix2 :
114
121
115
122
notable_bug_fix2
Original file line number Diff line number Diff line change @@ -458,7 +458,7 @@ def _compute_plot_data(self):
458
458
if isinstance (data , ABCSeries ):
459
459
label = self .label
460
460
if label is None and data .name is None :
461
- label = "None "
461
+ label = ""
462
462
if label is None :
463
463
# We'll end up with columns of [0] instead of [None]
464
464
data = data .to_frame ()
Original file line number Diff line number Diff line change @@ -1188,7 +1188,7 @@ def test_line_label_none(self):
1188
1188
assert ax .get_legend () is None
1189
1189
1190
1190
ax = s .plot (legend = True )
1191
- assert ax .get_legend ().get_texts ()[0 ].get_text () == "None "
1191
+ assert ax .get_legend ().get_texts ()[0 ].get_text () == ""
1192
1192
1193
1193
@pytest .mark .parametrize (
1194
1194
"props, expected" ,
Original file line number Diff line number Diff line change @@ -179,7 +179,7 @@ def test_label(self):
179
179
self .plt .close ()
180
180
_ , ax = self .plt .subplots ()
181
181
ax = s .plot (legend = True , ax = ax )
182
- self ._check_legend_labels (ax , labels = ["None " ])
182
+ self ._check_legend_labels (ax , labels = ["" ])
183
183
self .plt .close ()
184
184
# get name from index
185
185
s .name = "NAME"
You can’t perform that action at this time.
0 commit comments