propWINS | R Documentation |
Proportion of wins/losses/ties given the win odds and the win ratio
propWINS(WO, WR, Overall = 1, alpha = NULL, N = NULL)
WO |
win odds. |
WR |
win ratio. |
Overall |
number of comparisons, the sample size of the active treatment multiplied by the sample size of the placebo. The default is 1, hence gives the proportion. |
alpha |
significance level for the win ratio confidence interval. The default is |
N |
the combined sample size of two treatment groups. The default is |
a data frame with a number (or proportion if Overall = 1
) of wins/losses/ties. If alpha
is specified returns also WR
confidence interval.
For the relationship between win odds and win ratio see
Gasparyan SB et al. "Hierarchical Composite Endpoints in COVID-19: The DARE-19 Trial". Case Studies in Innovative Clinical Trials, Chapter 7 (2023): 95-148. Chapman and Hall/CRC. doi:10.1201/9781003288640-7.
The win ratio CI uses the standard error presented in
Yu RX, Ganju J. (2022) "Sample size formula for a win ratio endpoint." Statistics in Medicine 41.6: 950-63. doi:10.1002/sim.9297.
# Example 1
propWINS(WR = 2, WO = 1.5)
# Example 2 - Back-calculation
COVID19HCE <- hce(GROUP = COVID19$GROUP, TRTP = COVID19$TRTP)
res <- calcWINS(COVID19HCE)
WR <- res$WR1$WR
WO <- res$WO$WO
Overall <- res$summary$TOTAL
propWINS(WR = WR, WO = WO, Overall = Overall)
## Verify
res$summary
# Example 3 - Confidence interval
propWINS(WR = 1.4, WO = 1.3, alpha = 0.05, Overall = 2500)
propWINS(WR = 2, WO = 1.5, alpha = 0.01, N = 500)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.