calcWO.data.frame: Win odds calculation using a data frame

View source: R/calcWO_data_frame.R

calcWO.data.frameR Documentation

Win odds calculation using a data frame

Description

Win odds calculation using a data frame

Usage

## S3 method for class 'data.frame'
calcWO(x, AVAL, TRTP, ref, 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.

ref

the reference treatment group.

alpha

significance level. The default is 0.05.

WOnull

the null hypothesis. The default is 1.

...

additional parameters.

Value

a data frame containing the win odds and its confidence interval. It contains the following columns:

  • WO calculated win odds.

  • LCL lower confidence limit.

  • UCL upper confidence limit.

  • SE standard error of the 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.

  • WP calculated win probability.

  • WP_SE standard error of the win probability.

  • WP_SD standard deviation of the win probability, calculated as WP_SE multiplied by sqrt(N).

  • N total number of patients in the analysis.

References

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

See Also

calcWO(), calcWO.hce(), calcWO.formula().

Examples

data(HCE4)
calcWO(x = HCE4, AVAL = "AVAL", TRTP = "TRTP", ref = "P")

hce documentation built on Oct. 16, 2024, 9:06 a.m.