Choose by task
| Question | Start with | Use next when needed |
|---|---|---|
| What is in my dataset? | describe_data() |
assess_distribution() and
assess_variance() for selected continuous variables |
| How do I describe participants by group? | summary_table() |
add_p(), add_total(), or
add_proportion() only when justified |
| How do I report outbreak or surveillance measures? | epi_table() |
Review its denominator and effect-measure components |
| How do I format final results calculated elsewhere? | as_stats_table() |
customise_table() and save_output()
|
| Do groups differ for one variable? | compare_groups() |
effect_size() for magnitude; audit helpers for
review |
| Are two continuous variables associated? | correlation() |
plot_correlation() |
| What is a proportion or rate? |
proportion_stats() or rate_stats()
|
— |
| What are RR, OR, and risk difference? | crosstabs() |
— |
| How do I change the finished table? | to_gt() |
customise_table(), to_flextable(),
save_output()
|
The core distinction
summary_table() describes many
variables for a descriptive table.
compare_groups() tests one variable across
one group variable. assess_distribution() describes the
empirical shape of selected continuous variables, not an inferential
test choice.
assess_variance() describes group SDs, variances, and
spread ratios for selected continuous variables. It is diagnostic only:
Welch methods do not require equal variances, and the function does not
select an inferential test.
Objects remain inspectable
Every main function returns an object containing the data behind the
display. The default print method is the publication-ready table.
Components such as $summary, $inferential,
$recommendations, and $notes are available for
programming and review; they are not extra steps required for routine
use.
result <- compare_groups(mtcars, variable = mpg, group = am)
result$inferential
diagnostics_stats(result)A minimal decision tree
Participant-level data
└─ describe_data()
├─ assess_distribution() → how to present selected continuous variables
├─ assess_variance() → how observed spread differs across groups
├─ summary_table() → Table 1 / participant characteristics
└─ compare_groups() → one inferential question
Outbreak or surveillance data
└─ epi_table() → events, denominators, risks, or rates
Already calculated results
└─ as_stats_table() → preserve values; style and export only
The Start here article explains the minimal workflow; the birth-weight case study applies it end to end. Missing data and denominators explains how every analysis population and displayed percentage is formed.
For a compact, user-facing table of arguments and defaults for every exported function, see Function options.
For the complete and auditable test = "auto" decision
table—including Welch versus Student/ANOVA, marked-skew rank routes,
sparse categorical tables, and paired/repeated methods—see Inferential tests and assumptions.