gammaEffectSizeLONG: Calculate Gamma effect sizes from a longitudinal data set.

gammaEffectSizeLongR Documentation

Calculate Gamma effect sizes from a longitudinal data set.

Description

Function for calculating non-parametric effect size for any specified quantile(s) as proposed by Akinshin.

Usage

gammaEffectSizeLong(
	data_table,
  variable,
  year_1,
  year_2,
  quantiles=1:9/10,
  digits=3)

Arguments

data_table

Longitudinal dataset (e.g., from the SGP package) from which to calculate effect sizes over specified years.

variable

Character (length 1) identifying the variable of interest (e.g., ‘SCALE_SCORE’).

year_1

Character identifying the comparison/control year(s). Can be multiple years. Variable assumed to be named ‘YEAR’.

year_2

Character identifying the year(s) of interest (treatment). Can be multiple years. Variable assumed to be named ‘YEAR’.

quantiles

Argument to specify quantile(s) to evaluate (between 0 and 1). Default is Deciles.

digits

Number of digits to round results to.

Details

Typical use of the function is to submit scale score or SGP data from which to calculate effect sizes (standardized differences in the two distributions at the given quantiles). This function applies the lower level function Andrey Akinshin proposed in a June 25, 2020 blog post - https://aakinshin.net/posts/nonparametric-effect-size/ to longitudinal data typically produced from SGP analyses. Usually done within a data.table

Value

Function returns an effect size (numeric) vector of length quantiles that is easily combined into a table using data.table. See example below.

Author(s)

Damian W. Betebenner dbetebenner@nciea.org and Adam Van Iwaarden avaniwaarden@nciea.org

Examples

	## Not run: 
		###  require(SGPdata)
		###  require(data.table)
		sgpData_LONG_COVID[,
  			as.list(gammaEffectSizeLong(.SD, "SCALE_SCORE", "2019", "2021")),
				keyby=c("CONTENT_AREA", "GRADE")]
	
## End(Not run)

CenterForAssessment/cfaTools documentation built on June 2, 2022, 9:23 a.m.