Compute number of unique values for each level in a column.

replyr_uniqueValues(x, cname)

Arguments

x

tbl or item that can be coerced into such.

cname

name of columns to examine, must not be equal to 'replyr_private_value_n'.

Value

unique values for the column.

Examples

d <- data.frame(x=c(1,2,3,3)) replyr_uniqueValues(d,'x')
#> # A tibble: 3 x 2 #> x replyr_private_value_n #> <dbl> <dbl> #> 1 1 1 #> 2 2 1 #> 3 3 2