combine_date_time_cols | R Documentation |
Combine date and time columns into a single DateTime column
combine_date_time_cols(.data, tz = NULL)
.data |
(data.frame) A data frame or data frame extension (e.g. a tibble) |
tz |
(character) a time zone name (default: time zone of the POSIXt object x) |
(data.frame) An object of the same type as .data
df <- data.frame( date_a = as.Date(c("2020-01-01", "2020-01-02")), date_b = as.POSIXct(c("2020-02-01", "2020-02-02")), time_a = as.POSIXct(c("1900-01-01 01:01:01", "1900-01-01 02:02:02")), time_b = as.POSIXct(c("1900-01-01 01:01:01", "1900-01-01 02:02:02")) ) combine_date_time_cols(df)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.