| cox_index | R Documentation |
Computes the What Works Clearinghouse (WWC) Cox index, a standardized effect size for a binary (dichotomous) covariate. The Cox index places the difference between two proportions on a scale comparable to Hedges' g, so it can be classified with the same baseline-equivalence thresholds.
cox_index(x, treatment, na.rm = TRUE)
x |
A binary covariate (numeric |
treatment |
Vector the same length as |
na.rm |
Logical; drop rows where |
The index is d_{Cox} = (\mathrm{logit}(p_t) - \mathrm{logit}(p_c)) /
1.65, where p_t and p_c are the proportions in the "event"
category for the treatment and comparison groups.
A single numeric value: the Cox index. Returns NA (with a warning)
when a group proportion is exactly 0 or 1, where the index is undefined.
What Works Clearinghouse (2022). Procedures Handbook (Version 5.0). U.S. Department of Education.
x <- c(1, 1, 1, 1, 0, 1, 0, 0)
g <- c(1, 1, 1, 1, 0, 0, 0, 0)
cox_index(x, g)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.