R/all_unique.R

Defines functions all_unique

Documented in all_unique

#' Test that all values are unique in an array or vector
#'
#' @param x A numeric or array object.
#' @return logical
#'
#' @export
all_unique <- function(x) {
    return(!any(duplicated(x, MARGIN = 0)))
}
crcox/latticize documentation built on Dec. 19, 2021, 6:19 p.m.