R/wrap.R

Defines functions dtt_wrap.hms dtt_wrap

Documented in dtt_wrap

#' Wrap
#'
#' @param x A date/time vector.
#' @param ... Unused.
#' @export
#' @examples
#' dtt_wrap(hms::as_hms("24:00:00"))
dtt_wrap <- function(x, ...) {
  UseMethod("dtt_wrap")
}

#' @export
dtt_wrap.hms <- function(x, ...) {
  chk_unused(...)
  dtt_time(as.POSIXlt(x))
}

Try the dttr2 package in your browser

Any scripts or data that you put into this service are public.

dttr2 documentation built on July 10, 2020, 5:06 p.m.