Fulfill Welch Two Sample t-test (t.test) and calculate Cohen's d as well as determine significance by p-value and effect size threshold.
Usage
ttest_cohens_d(values, groups, alpha = 0.05, power = 0.9, alternative = "two.sided", paired = FALSE, var.equal = FALSE)
Arguments
values
A scalar vector. Length of both of two vectors, values and groups, should be same.
groups
Experiment groups for the vector 'values'. Length of both of two vectors, values and groups, should be same.
The number of groups is not limited to two, such as group <- c('A','A','A','B','B').
alpha
P-value threshold
power
Give the statistical power you desired for output significant list
alternative
Choose one of these c("two.sided", "less", "greater"). Default is "two.sided".
paired
if two groups are paired, set it to TRUE. Default is FALSE.
var.equal
if two groups are assumed to have same variance, set it to TRUE. Default is FALSE.