add_count_se | R Documentation |
Add a new column named "n" with (optionally per-group) sums/counts.
add_count_se(x, groupingVars = NULL, wt = NULL, sort = FALSE)
x |
data.frame to tally/count |
groupingVars |
character vector of column names to group by. |
wt |
character optional column name containing row-weights (passed to count/tally) |
sort |
logical if TRUE sort result in descending order |
Note: dplyr::count
, dplyr::add_count
,
dplyr::tally
, and dplyr::add_tally
are not S3
methods, so it may not be practical to re-dispatch seplyr
calls
to these dplyr
implementations.
.data with added column n, containing counts.
add_count
datasets::iris %.>% count_se(., wt = "Sepal.Width", groupingVars= c('Species'))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.