R/of_type.R

Defines functions is_discrete is_numeric is_date

is_date <- function(x) {
  inherits(x, "Date") ||
  inherits(x, "Time") ||
  inherits(x, "Datetime")
}

is_numeric <- function(x) {
  is.numeric(x)
}

is_discrete <- function(x) {
  !is_numeric(x)
}
schloerke/autocogs documentation built on June 29, 2018, 10:43 p.m.