lunique: The number of unique elements in an object

Description Usage Details Value Examples

View source: R/data_functions.R

Description

Function to calculate the length of the numebr of unique elements in a data object.

Usage

1

Details

Just a super convenient wrapper for the length(unique(x)) combination. See ?unique for more details.

Value

The number of unique elements

Examples

1
2
3
4
5
6
lunique(iris$Species)
[1] 3

sapply(iris, lunique)
Sepal.Length  Sepal.Width Petal.Length  Petal.Width      Species
35           23           43           22            3

andrewjameshaynes/helpeR documentation built on May 28, 2019, 2:44 p.m.