diff --git a/ci/code_checks.sh b/ci/code_checks.sh index dbb799779c1c4..7620fa3468b6a 100755 --- a/ci/code_checks.sh +++ b/ci/code_checks.sh @@ -300,7 +300,6 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then -i "pandas.TimedeltaIndex.nanoseconds SA01" \ -i "pandas.TimedeltaIndex.seconds SA01" \ -i "pandas.TimedeltaIndex.to_pytimedelta RT03,SA01" \ - -i "pandas.Timestamp PR07,SA01" \ -i "pandas.Timestamp.as_unit SA01" \ -i "pandas.Timestamp.asm8 SA01" \ -i "pandas.Timestamp.astimezone SA01" \ @@ -319,9 +318,9 @@ if [[ -z "$CHECK" || "$CHECK" == "docstrings" ]]; then -i "pandas.Timestamp.isocalendar SA01" \ -i "pandas.Timestamp.isoformat SA01" \ -i "pandas.Timestamp.isoweekday SA01" \ - -i "pandas.Timestamp.max PR02,PR07,SA01" \ + -i "pandas.Timestamp.max PR02" \ -i "pandas.Timestamp.microsecond GL08" \ - -i "pandas.Timestamp.min PR02,PR07,SA01" \ + -i "pandas.Timestamp.min PR02" \ -i "pandas.Timestamp.minute GL08" \ -i "pandas.Timestamp.month GL08" \ -i "pandas.Timestamp.month_name SA01" \ diff --git a/pandas/_libs/tslibs/timestamps.pyx b/pandas/_libs/tslibs/timestamps.pyx index 31c9681462a10..c1b615839c8cc 100644 --- a/pandas/_libs/tslibs/timestamps.pyx +++ b/pandas/_libs/tslibs/timestamps.pyx @@ -1297,10 +1297,24 @@ class Timestamp(_Timestamp): ---------- ts_input : datetime-like, str, int, float Value to be converted to Timestamp. - year, month, day : int - hour, minute, second, microsecond : int, optional, default 0 + year : int + Value of year. + month : int + Value of month. + day : int + Value of day. + hour : int, optional, default 0 + Value of hour. + minute : int, optional, default 0 + Value of minute. + second : int, optional, default 0 + Value of second. + microsecond : int, optional, default 0 + Value of microsecond. tzinfo : datetime.tzinfo, optional, default None + Timezone info. nanosecond : int, optional, default 0 + Value of nanosecond. tz : str, pytz.timezone, dateutil.tz.tzfile or None Time zone for time which Timestamp will have. unit : str @@ -1316,6 +1330,11 @@ class Timestamp(_Timestamp): datetime-like corresponds to the first (0) or the second time (1) the wall clock hits the ambiguous time. + See Also + -------- + Timedelta : Represents a duration, the difference between two dates or times. + datetime.datetime : Python datetime.datetime object. + Notes ----- There are essentially three calling conventions for the constructor. The