count_vars | R Documentation |
Count all or many variables in a data.frame (depth 1 level) and display the results as list of data.frame. This function intended for interactive use.
count_vars(x, ..., sort = TRUE, name = NULL, prop = FALSE)
x |
A data frame, data frame extension (e.g. a tibble), or a lazy data frame (e.g. from dbplyr or dtplyr). |
... |
Variables to count (one level); If not supply, count all variables. |
sort |
If |
name |
The name of the new column in the output. |
prop |
If |
A named list of data.frame
# Count All variables
count_vars(iris)
# Count Specified variables
count_vars(iris, Species, Sepal.Length)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.