R/helpers.R

Defines functions same new_id

new_id <- function(prefix = "ID") {
  paste0(
    prefix, "-",
    as.integer(Sys.time()),
    "-",
    paste0(sample(c(letters, LETTERS), size = 4), collapse = "")
  )
}

same <- function(x) {
  all(x[1] == x)
}

Try the ladder package in your browser

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

ladder documentation built on June 8, 2025, 11:29 a.m.