Compute a table with analysis of two groups comparisons

Description

For each column of a dataframe, generate a row in a resulting table that contains basic descriptive statistics, effect size, p-value, and confidence intervals for a two group comparions, where the grouping variable is separately given.

Usage

1
twoGroupComparisons(vars, v0, conf.level = 0.95, paired = FALSE)

Arguments

vars

Dataframe of continuous variables.

v0

Binary variable that builds the two groups.

conf.level

Confidence level used in computation of confidence intervals.

paired

Logical, indicate whether comparisons are paired or not.

Value

A list consisting of the following elements:

raw

Matrix that contains the above as raw numbers.

formatted

The same table where numbers are formatted and confidence intervals are given as character string.

Author(s)

Kaspar Rufibach (maintainer), kaspar.rufibach@gmail.com,
http://www.kasparrufibach.ch

Examples

1
2
3
4
5
set.seed(1977)
v0 <- round(runif(200, 0, 1))
v1 <- rnorm(200)
v2 <- rgamma(200, 2, 1)
twoGroupComparisons(vars = data.frame(v1, v2), v0) 

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.