Series.dt
can be used to access series values as datetimelike and return multiple properties. Series.dt.time
Pandas Series.dt.time
returns an empty array of Python datetime.time objects.
Syntax: Series.dt.time
Parameter: None
Returns : numpy array
Example # 1: Use the Series.dt.time
attribute to return the time property of the underlying data a Series object.
|
Output:
We will now use the Series.dt.time
attribute to return the time property of the underlying data of this Series object.
|
Output:
As we can see from the output, the Series.dt.time
attribute successfully accessed and returned the time property of the underlying data on this series object.
Example # 2: Use the Series.dt.time
attribute to return the time property of the underlying data of this Series object.
|
Exit:
Now we will use the Series.dt.time attribute
to return the time property of the underlying data of this Series object.
|
Output:
As we can see from the output, the Series.dt.time
attribute successfully accessed and returned the time property of the underlying data in the given series object .