Description Usage Arguments Value
Compare distributions using a Chi-Squared test
1 | compare_distros(column_names, by, data, digits = 4L)
|
column_names |
Column names of variables |
by |
Name of a grouping variable |
data |
Data frame containing variables 'column_names' and 'by' |
digits |
Number of decimal digits in 'pval' column |
A data frame with columns "variable", "by", "pval", "pvalue". The "variable" column contains the name of the variables whose distributions are compared between the levels of the 'by' variable whose name is contained in the "by" column. The "pval" column contains the p-value resulting from the comparison using Pearson's Chi-squared test, rounded to 'digits' decimal digits for better readability. The "pvalue" column contains the exact p-value.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.