pandas.to_timedelta¶
- pandas.to_timedelta(arg, box=True, unit='ns')¶
Convert argument to timedelta
Parameters: arg : string, timedelta, array of strings (with possible NAs)
box : boolean, default True
If True returns a Series of the results, if False returns ndarray of values
unit : unit of the arg (D,s,ms,us,ns) denote the unit, which is an integer/float number
Returns: ret : timedelta64/arrays of timedelta64 if parsing succeeded