Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Base R function for length(unique(x)) #149

Open
hughjonesd opened this issue Jul 22, 2023 · 0 comments
Open

Base R function for length(unique(x)) #149

hughjonesd opened this issue Jul 22, 2023 · 0 comments

Comments

@hughjonesd
Copy link

It's common to need to know how many unique elements there are in a vector. This often happens on the REPL during exploration of data. A single function like

nunique <- function (x) length(unique(x))

could save time and help readability.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant