View source: R/parametric-measures.R
LRM | R Documentation |
Calculates the log ratio of medians effect size index
LRM(
A_data,
B_data,
condition,
outcome,
baseline_phase = NULL,
intervention_phase = NULL,
improvement = "increase",
delta_method = FALSE,
confidence = 0.95
)
A_data |
vector of numeric data for A phase. Missing values are dropped. |
B_data |
vector of numeric data for B phase. Missing values are dropped. |
condition |
vector identifying the treatment condition for each observation in the series. |
outcome |
vector of outcome data for the entire series. |
baseline_phase |
character string specifying which value of
|
intervention_phase |
character string specifying which value of
|
improvement |
character string indicating direction of improvement. Default is "increase". |
delta_method |
logical value indicating whether to use delta method to
approximate variance of log ratio of medians. Default is |
confidence |
confidence level for the reported interval estimate. Set to
|
The ratio of medians effect size parameter is defined as the ratio of the medians of the outcomes in different phases. The log ratio of the medians is the natural logarithm of the ratio of medians. This effect size is appropriate for outcomes that are skewed, symmetric but highly leptokurtic, or right-censored (Bonett & Price Jr, 2020).
A data frame containing the estimate, standard error, and confidence interval.
Bonett, D. G. & Price Jr, R. M. (2020). Confidence Intervals for Ratios of Means and Medians. Journal of Educational and Behavioral Statistics, 45(6), 750–770. doi:\Sexpr[results=rd]{tools:::Rd_expr_doi("10.3102/1076998620934125")}
Bonett, D. G., & Price, R. M. (2020). Interval estimation for linear functions of medians in within-subjects and mixed designs. British Journal of Mathematical and Statistical Psychology, 73(2), 333-346. doi:\Sexpr[results=rd]{tools:::Rd_expr_doi("10.1111/bmsp.12171")}
A <- c(20, 20, 26, 25, 22, 23)
B <- c(28, 25, 24, 27, 30, 30, 29)
LRM(A_data = A, B_data = B)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.