pandas.Timedelta.total_seconds

Timedelta.total_seconds()

Total seconds in the duration.

Examples

>>> td = pd.Timedelta('1min')
>>> td
Timedelta('0 days 00:01:00')
>>> td.total_seconds()
60.0

© 2008–2011, AQR Capital Management, LLC, Lambda Foundry, Inc. and PyData Development Team
© 2011–2025, Open source contributors
Licensed under the 3-clause BSD License.
https://pandas.pydata.org/pandas-docs/version/2.3.0/reference/api/pandas.Timedelta.total_seconds.html