cohens_d: Calculate Cohen's d given some descriptive statistics

Description Usage Arguments Value Examples

View source: R/cohens_d.R

Description

Calculate Cohen's d given some descriptive statistics

Usage

1
cohens_d(mean.one, mean.two, sd.one, sd.two, sd = c("same", "diff"))

Arguments

mean.one

consumes the mean of first group

mean.two

consumes the mean of second group

sd.one

consumes the standard deviation of first group

sd.two

consumes the standard deviation of second group. This can be left empty if the groups share the same standard deviation.

sd

Type "same" if both groups have the same sd. Type "diff" if the groups do not have the same standard deviation. In this case, the pooled standard deviation is used.

Value

A string containing Cohen's d statistic that informs user of effect size

Examples

1
2
cohens_d(0, 1.4, 0.6, sd = "same")
cohens_d(mean.one = 0, mean.two = 1, sd.one = 0.5, sd.two = 0.6, sd = "diff")

andr3wli/powerPsych documentation built on Dec. 31, 2020, 7:46 p.m.