# stratWO.data.frame: Stratified win odds with adjustment In hce: Design and Analysis of Hierarchical Composite Endpoints

 stratWO.data.frame R Documentation

## Stratified win odds with adjustment

### Usage

``````## S3 method for class 'data.frame'
stratWO(
x,
AVAL,
TRTP,
STRATA,
ref,
COVAR = NULL,
alpha = 0.05,
WOnull = 1,
...
)
``````

### Arguments

 `x` a data frame containing subject-level data. `AVAL` variable in the data with ordinal analysis values. `TRTP` the treatment variable in the data. `STRATA` a character variable for stratification. `ref` the reference treatment group. `COVAR` a numeric covariate. `alpha` the reference treatment group. `WOnull` the null hypothesis. The default is 1. `...` additional parameters.

### Value

a data frame containing the following columns:

• WO stratified (or adjusted/stratified) win odds.

• WOnull win odds of the null hypothesis (specified in the `WOnull` argument).

• alpha two-sided significance level for calculating the confidence interval (specified in the `alpha` argument).

• Pvalue p-value associated with testing the null hypothesis.

• N total number of patients in the analysis.

• Type "STRATIFIED" or "STRATIFIED/ADJUSTED" depending on whether `COVAR` is specified.

### References

Gasparyan SB et al. (2021) "Adjusted win ratio with stratification: calculation methods and interpretation." Statistical Methods in Medical Research 30.2: 580-611. doi:10.1177/0962280220942558.

`stratWO()`.

### Examples

``````# Stratified win odds
res <- stratWO(x = KHCE, AVAL = "AVAL", TRTP = "TRTP",
STRATA = "STRATAN", ref = "P")
res
## Compare with the win odds in each stratum separately
lapply(split(KHCE, KHCE\$STRATAN), calcWO, AVAL = "AVAL", TRTP = "TRTP", ref = "P")
# Stratified and adjusted win odds
res <- stratWO(x = KHCE, AVAL = "AVAL", COVAR = "EGFRBL",
TRTP = "TRTP", STRATA = "STRATAN", ref = "P")
res
``````

hce documentation built on May 29, 2024, 5:52 a.m.