Description Usage Arguments Details Value
magic_table
is the top-level function for magic_table_numeric
and
magic_table_categorical
.
1 2 3 | magic_table(dataset, vars, var_labels, cat_labels, stat_func, condvar_wide,
condvar_wide_labels, condvar_long, condvar_long_labels, categorical = NULL,
...)
|
dataset |
a data.frame object, or object that can be coerced to a data.frame. |
vars |
a vector of character strings containing the names of the variables for which summary statistics should be computed. |
var_labels |
a vector of character strings containing the labels for the variables
in |
cat_labels |
a vector of character strings containing the labels for the categories
of the variables contained in |
stat_func |
a function for calculating the summary statistics for the variables specified in |
condvar_wide |
a character string indicating a variable in |
condvar_wide_labels |
a character vector containing the labels for the different values
of |
condvar_long |
a character string indicating a variable in |
condvar_long_labels |
a character vector containing the labels for the different values
of |
categorical |
a logical value indicating whether |
... |
additional variables to be passed to |
stat_labels |
a vector of character strings containing the labels for the values
in the output from |
The main purpose of the magic_table
function is to serve as a top-level function
for calling either magic_table_numeric
or magic_table_categorical
. For convenience,
magic_table
will attempt to figure out which one should be called based on the classes
of the variables contained in vars
.
a magic_table
object, the result of a call to either magic_table_numeric
or magic_table_categorical
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.