Skip to content

Commit 76d86a9

Browse files
author
sah0725
committed
docs: fix code formatting and remove f-strings for compatibility
1 parent 544e8a0 commit 76d86a9

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

doc/source/user_guide/io.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1828,7 +1828,7 @@ Best practices
18281828
.. ipython:: python
18291829
18301830
from io import StringIO
1831-
1831+
18321832
def test_roundtrip_precision(df, float_format):
18331833
"""Test if a float_format preserves data during CSV roundtrip."""
18341834
csv_string = df.to_csv(index=False, float_format=float_format)
@@ -1841,7 +1841,8 @@ Best practices
18411841
# Test different precisions
18421842
for fmt in ['%.6g', '%.10g', '%.15g']:
18431843
success = test_roundtrip_precision(test_df, fmt)
1844-
print(f"Format {fmt}: {'' if success else ''} roundtrip success")
1844+
status = '' if success else ''
1845+
print("Format {}: {} roundtrip success".format(fmt, status))
18451846
18461847
.. ipython:: python
18471848
:suppress:

0 commit comments

Comments
 (0)