4.4 hms

The hms package provides a simple class for storing durations or time-of-day values and displaying them in the hh:mm:ss format.

hms() is a constructor that accepts second, minute, hour and day components as numeric vectors.

round_hms() and trunc_hms() are onvenience functions to round or truncate to a multiple of seconds. They are similar to floor_date() and ceiling_date() in Section 4.2.2, but the time unit can only be seconds