Helper to [getDescriptionStatsBy()]
prPropDescs(
x,
by,
name,
default_ref,
prop_fn,
html,
digits,
digits.nonzero,
numbers_first,
useNA,
useNA.digits,
percentage_sign,
missing_value,
names_of_missing,
NEJMstyle
)
A [base::by] list
If a data.frame it will be used as the data source for the variables in the ...
parameter.
If it is a single variable it will be the core value that want the statistics for.
In the print this is equivalent to the output of this function.
The variable that you want to split into different columns
The name of the row
The default reference when dealing with proportions. When using `dplyr` syntax (`tidyselect`) you can specify a named vector/list for each column name.
The method used to describe proportions, see describeProp
.
If HTML compatible output should be used. If FALSE
it outputs LaTeX formatting
The number of decimals used
The number of decimals used for values that are close to zero
If the number should be given or if the percentage should be presented first. The second is encapsulated in parentheses ().
This indicates if missing should be added as a separate
row below all other. See table
for useNA
-options.
Note: defaults to ifany and not "no" as table
does.
The number of digits to use for the
missing percentage, defaults to the overall digits
.
If you want to suppress the percentage sign you can set this variable to FALSE. You can also choose something else that the default % if you so wish by setting this variable.
Value that is substituted for empty cells. Defaults to "-"
Optional character vector containing the names of returned statistics,
in case all returned values for a given by
level are missing. Defaults to NULL
Adds - no (%) at the end to proportions