is_uniq(1:10)
is_uniq(c(1,1,2,3), c(1,2,2,3))
if (FALSE) {
# returns FALSE where a "5" appears
is_uniq(c(1:10, 5))
}
library(magrittr)
if (FALSE) {
# this fails 4 times
mtcars %>% assert(is_uniq, qsec)
}
Run the code above in your browser using DataLab