|
81 | 81 | PerformanceWarning, |
82 | 82 | ) |
83 | 83 | from pandas.util._decorators import ( |
84 | | - Appender, |
85 | | - Substitution, |
86 | 84 | cache_readonly, |
87 | 85 | ) |
88 | 86 | from pandas.util._exceptions import find_stack_level |
@@ -1774,18 +1772,14 @@ class DatelikeOps(DatetimeLikeArrayMixin): |
1774 | 1772 | Common ops for DatetimeIndex/PeriodIndex, but not TimedeltaIndex. |
1775 | 1773 | """ |
1776 | 1774 |
|
1777 | | - @Substitution( |
1778 | | - URL="https://docs.python.org/3/library/datetime.html" |
1779 | | - "#strftime-and-strptime-behavior" |
1780 | | - ) |
1781 | 1775 | def strftime(self, date_format: str) -> npt.NDArray[np.object_]: |
1782 | 1776 | """ |
1783 | 1777 | Convert to Index using specified date_format. |
1784 | 1778 |
|
1785 | 1779 | Return an Index of formatted strings specified by date_format, which |
1786 | 1780 | supports the same string format as the python standard library. Details |
1787 | 1781 | of the string format can be found in `python string format |
1788 | | - doc <%(URL)s>`__. |
| 1782 | + doc <https://docs.python.org/3/library/datetime.html>`__. |
1789 | 1783 |
|
1790 | 1784 | Formats supported by the C `strftime` API but not by the python string format |
1791 | 1785 | doc (such as `"%%R"`, `"%%r"`) are not officially supported and should be |
@@ -2258,7 +2252,6 @@ def _round(self, freq, mode, ambiguous, nonexistent): |
2258 | 2252 | result = result.view(self._ndarray.dtype) |
2259 | 2253 | return self._simple_new(result, dtype=self.dtype) |
2260 | 2254 |
|
2261 | | - @Appender((_round_doc + _round_example).format(op="round")) |
2262 | 2255 | def round( |
2263 | 2256 | self, |
2264 | 2257 | freq, |
@@ -2363,7 +2356,6 @@ def round( |
2363 | 2356 | """ |
2364 | 2357 | return self._round(freq, RoundTo.NEAREST_HALF_EVEN, ambiguous, nonexistent) |
2365 | 2358 |
|
2366 | | - @Appender((_round_doc + _floor_example).format(op="floor")) |
2367 | 2359 | def floor( |
2368 | 2360 | self, |
2369 | 2361 | freq, |
@@ -2468,7 +2460,6 @@ def floor( |
2468 | 2460 | """ |
2469 | 2461 | return self._round(freq, RoundTo.MINUS_INFTY, ambiguous, nonexistent) |
2470 | 2462 |
|
2471 | | - @Appender((_round_doc + _ceil_example).format(op="ceil")) |
2472 | 2463 | def ceil( |
2473 | 2464 | self, |
2474 | 2465 | freq, |
|
0 commit comments