create_table generates a frequency distribution table from a vector,
list or data frame input.
Usage
create_table(source, dec_pos = 2)
Arguments
source
Vector, list or data frame input. If the source is of class
list, it will be simplified to a vector using unlist.
dec_pos
Number of positions to return in the frequency and cumulative
frequency variables. Defaults to two positions following the decimal.
Value
A data frame containing the frequency distribution table.
If an error or warning occurs, a message will be printed to the console and
the function will return NULL.
Details
create_table returns a data frame that includes five variables:
group, count, frequency, cumulative count and cumulative frequency.