freq_tbl {fastrep} | R Documentation |
freq_tbl
Description
This function creates a frequency table, you only need to supply a data.frame and the variable to make the table.
Usage
freq_tbl(
obj,
var,
sort_by = {
{
var
}
},
desc = FALSE
)
Arguments
obj |
Object used to create the table. Data frame, list or environment (or object coercible by as.data.frame to a data frame) |
var |
Variable that you want the table (not written in string format) |
sort_by |
Variable you want to sort the |
desc |
if you want decreasing order put |
Value
A tibble with 4 rows and 3 columns
Note
By default the sort_by
is in alphabetical order of var
Examples
iris %>%
fastrep::freq_tbl(Species) %>%
fastrep::tbl("You can combine this function too!")
[Package fastrep version 0.7 Index]