pandas.DatetimeIndex.second#
- property DatetimeIndex.second[source]#
The seconds of the datetime.
This attribute returns the second component of each datetime value in the DatetimeIndex.
See also
DatetimeIndex.minuteThe minutes of the datetime.
DatetimeIndex.microsecondThe microseconds of the datetime.
DatetimeIndex.nanosecondThe nanoseconds of the datetime.
Examples
>>> idx = pd.date_range("2000-01-01", periods=3, freq="s") >>> idx.second Index([0, 1, 2], dtype='int32')