Skip to content

Commit 646dc9f

Browse files
remove hour and microsecond
1 parent 18a1adc commit 646dc9f

File tree

1 file changed

+1
-53
lines changed

1 file changed

+1
-53
lines changed

pandas/_libs/tslibs/timestamps.pyx

Lines changed: 1 addition & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -613,31 +613,6 @@ cdef class _Timestamp(ABCTimestamp):
613613
return out[0]
614614

615615
@property
616-
def microsecond(self) -> int:
617-
"""
618-
Return the microsecond component of the Timestamp.
619-
620-
The microsecond component represents the number of microseconds
621-
(0 to 999,999) of the Timestamp.
622-
623-
Returns
624-
-------
625-
int
626-
Microsecond component of the Timestamp, ranging from 0 to 999,999.
627-
628-
See Also
629-
--------
630-
Timestamp.second : Return the second component of the Timestamp.
631-
Timestamp.minute : Return the minute component of the Timestamp.
632-
633-
Examples
634-
--------
635-
>>> ts = pd.Timestamp('2024-08-23 14:30:15.123456')
636-
>>> ts.microsecond
637-
123456
638-
"""
639-
return self.microsecond
640-
641616
def max(self):
642617
"""
643618
A constant that represents the maximum valid date and time value.
@@ -662,6 +637,7 @@ cdef class _Timestamp(ABCTimestamp):
662637
"""
663638
return max
664639

640+
@property
665641
def min(self):
666642
"""
667643
Return the minimum representable Timestamp.
@@ -686,34 +662,6 @@ cdef class _Timestamp(ABCTimestamp):
686662
"""
687663
return min
688664

689-
def hour(self) -> int:
690-
"""
691-
Returns the hour component of the timestamp.
692-
693-
The hour is represented as an integer ranging from 0 to 23, where 0 corresponds
694-
to midnight (00:00) and 23 corresponds to the last hour of the day (23:00).
695-
696-
Returns
697-
-------
698-
int
699-
The hour component of the timestamp as an integer between 0 and 23.
700-
701-
See Also
702-
--------
703-
Timestamp.minute : Similar property indicating the minute of the timestamp.
704-
705-
Examples
706-
--------
707-
>>> ts = pd.Timestamp('2020-03-14T12:32:52.192548651')
708-
>>> ts.hour()
709-
12
710-
711-
>>> ts = pd.Timestamp('2020-03-14T22:43:12.192547851')
712-
>>> ts.hour()
713-
22
714-
"""
715-
return self.hour
716-
717665
@property
718666
def is_month_start(self) -> bool:
719667
"""

0 commit comments

Comments
 (0)