Skip to content

Commit 212e92d

Browse files
DOC: add SA01,ES01 for pandas.Timestamp.round
1 parent 529bcc1 commit 212e92d

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

pandas/_libs/tslibs/timestamps.pyx

+14
Original file line numberDiff line numberDiff line change
@@ -2015,6 +2015,12 @@ class Timestamp(_Timestamp):
20152015
"""
20162016
Round the Timestamp to the specified resolution.
20172017
2018+
This method rounds the given Timestamp down to a specified frequency
2019+
level. It is particularly useful in data analysis to normalize timestamps
2020+
to regular frequency intervals. For instance, rounding to the nearest
2021+
minute, hour, or day can help in time series comparisons or resampling
2022+
operations.
2023+
20182024
Parameters
20192025
----------
20202026
freq : str
@@ -2049,6 +2055,14 @@ timedelta}, default 'raise'
20492055
------
20502056
ValueError if the freq cannot be converted
20512057
2058+
See Also
2059+
--------
2060+
datetime.round : Similar behavior in native Python datetime module.
2061+
Timestamp.floor : Round the Timestamp downward to the nearest multiple
2062+
of the specified frequency.
2063+
Timestamp.ceil : Round the Timestamp upward to the nearest multiple of
2064+
the specified frequency.
2065+
20522066
Notes
20532067
-----
20542068
If the Timestamp has a timezone, rounding will take place relative to the

0 commit comments

Comments
 (0)