Skip to content

Commit 6fcd50d

Browse files
author
cloudboat
committed
remove %%
1 parent 0532ca4 commit 6fcd50d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pandas/core/arrays/datetimelike.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1788,9 +1788,9 @@ def strftime(self, date_format: str) -> npt.NDArray[np.object_]:
17881788
#strftime-and-strptime-behavior>`__.
17891789
17901790
Formats supported by the C `strftime` API but not by the python string format
1791-
doc (such as `"%%R"`, `"%%r"`) are not officially supported and should be
1792-
preferably replaced with their supported equivalents (such as `"%%H:%%M"`,
1793-
`"%%I:%%M:%%S %%p"`).
1791+
doc (such as `"%R"`, `"%r"`) are not officially supported and should be
1792+
preferably replaced with their supported equivalents (such as `"%H:%M"`,
1793+
`"%I:%M:%S %p"`).
17941794
17951795
Note that `PeriodIndex` support additional directives, detailed in
17961796
`Period.strftime`.
@@ -1817,7 +1817,7 @@ def strftime(self, date_format: str) -> npt.NDArray[np.object_]:
18171817
Examples
18181818
--------
18191819
>>> rng = pd.date_range(pd.Timestamp("2018-03-10 09:00"), periods=3, freq="s")
1820-
>>> rng.strftime("%%B %%d, %%Y, %%r")
1820+
>>> rng.strftime("%B %d, %Y, %r")
18211821
Index(['March 10, 2018, 09:00:00 AM', 'March 10, 2018, 09:00:01 AM',
18221822
'March 10, 2018, 09:00:02 AM'],
18231823
dtype='str')

0 commit comments

Comments
 (0)