compare_distros: Compare distributions using a Chi-Squared test

Description Usage Arguments Value

Description

Compare distributions using a Chi-Squared test

Usage

1
compare_distros(column_names, by, data, digits = 4L)

Arguments

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

Value

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.


cbaumbach/manyregs documentation built on May 13, 2019, 1:48 p.m.