View source: R/decimate_time.R
decimate_time | R Documentation |
Given a class of "hms" or "difftime" or "character" ("00:00:00") or "Period", convert to decimal format.
decimate_time(time, units = "hours")
time |
A date-time object or a character vector of hour minute second triples |
units |
character string: "hours", "minutes", "seconds" |
A numeric
library(lubridate)
decimate_time(time = "3:30:00",
units = "hours")
decimate_time(time = "3:30:00",
units = "minutes")
decimate_time(time = lubridate::hms("3:30:00"),
units = "minutes")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.