Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

40_unique-related_functions

Unique-Related Functions


Description

Convenience functions to test uniqueness, or to return the number of unique or duplication values, or a unique sorted vector.

The which.unique function returns a vector of indices.
This will be produce a vector of unique values, if the original vector is subsetted using the indices.

Usage

is.each.equal (x)
is.each.unique (x)

n.unique (x)
n.duplicated (x)

which.unique (x)

usv (x)

Arguments

x

An integer/numeric vector.

See Also

Examples

x <- c (2, 2, 1, 1, 10, 12)

n.unique (x)
usv (x)

vectools

Advanced Vector Toolkit

v0.2.0
GPL (>= 2)
Authors
Abby Spurdle
Initial release
2020-10-22

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.