Convert clock time to decimal equivalent
Arguments
- .col
column of type character or POSIXct to extract clocktimes from
to convert to decimal values
Author
Samuel P Callisto, PhD
Examples
timedf <- dplyr::tibble(ID = c(1, 1, 2),
DATETIME = c("2022-01-23T12:34:00", "2022-01-28T04:32:00", "2022-01-21T18:00:00"))
times <- lubridate::ymd_hms(timedf$DATETIME)
numeric_time(times)
#> [1] 12.57 4.53 18.00