etaSquaredTtest: Get an eta-squared effect size to accompany a t-test.

View source: R/statistics.R

etaSquaredTtestR Documentation

Get an eta-squared effect size to accompany a t-test.

Description

Calculate or bootstrap a confidence interval.

Usage

etaSquaredTtest(g1, g2 = NA, mu = 0, na.rm = TRUE)

Arguments

g1

A numeric vector (scores for group 1).

g2

A numeric vector (scores for group 2).

mu

A number for a single-sample t-test (default: 0).

na.rm

Boolean: remove NA's from g1 and g2 (default: TRUE).

Details

Eta-squared is a measure of effect size that expresses the propportion of variance explained by an effect. For a t-test, that 'effect' is the separation of the data into two groups. There is a way to do this for two groups, as well as for a single sample, comparing the mean to a given number. There is no way (now) to do this for a two-sample t-test comparing the difference in means to a hypothetical value, nor does this function differentiate between single-sided or two-sided t-tests.

Value

A number: the eta squared (effect size).

Examples

#

thartbm/handlocs documentation built on Feb. 18, 2025, 10:53 p.m.