R/unique.R
fct_unique.Rd
Unique values of a factor
fct_unique(f)
A factor.
f <- factor(letters[rpois(100, 10)]) unique(f) # in order of appearance#> [1] o f n j g l h k e i p q m r #> Levels: e f g h i j k l m n o p q rfct_unique(f) # in order of levels#> [1] e f g h i j k l m n o p q r #> Levels: e f g h i j k l m n o p q r