We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8d3dabb commit 730f9b6Copy full SHA for 730f9b6
pandas/_libs/tslibs/period.pyx
@@ -1295,6 +1295,25 @@ cdef class _Period(object):
1295
1296
@property
1297
def second(self):
1298
+ """
1299
+ Get the second component of the Period.
1300
+
1301
+ Returns
1302
+ -------
1303
+ int
1304
+ The second of the Period (ranges from 0 to 59).
1305
1306
+ See Also
1307
+ --------
1308
+ Period.hour : Get the hour component of the Period.
1309
+ Period.minute : Get the minute component of the Period.
1310
1311
+ Examples
1312
1313
+ >>> p = pd.Period("2018-03-11 13:03:12.050000")
1314
+ >>> p.second
1315
+ 12
1316
1317
base, mult = get_freq_code(self.freq)
1318
return psecond(self.ordinal, base)
1319
0 commit comments