Skip to content

Commit 284758d

Browse files
authored
Fix Styler.format() Excel example (#49971)
fix styler format excel example
1 parent 41db572 commit 284758d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/io/formats/style_render.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1110,7 +1110,7 @@ def format(
11101110
11111111
>>> df = pd.DataFrame({"A": [1, 0, -1]})
11121112
>>> pseudo_css = "number-format: 0§[Red](0)§-§@;"
1113-
>>> df.style.applymap(lambda v: css).to_excel("formatted_file.xlsx")
1113+
>>> df.style.applymap(lambda: pseudo_css).to_excel("formatted_file.xlsx")
11141114
... # doctest: +SKIP
11151115
11161116
.. figure:: ../../_static/style/format_excel_css.png

0 commit comments

Comments
 (0)