Wrapper function for historical data from binomial outcome.
historical_binomial( y0_treatment = NULL, N0_treatment = NULL, discount_function = "identity", y0_control = NULL, N0_control = NULL, alpha_max = 1, fix_alpha = FALSE, weibull_scale = 0.135, weibull_shape = 3, method = "fixed", .data = NULL )
y0_treatment | scalar. Number of events for the historical treatment arm. |
---|---|
N0_treatment | scalar. Number of observations of the historical treatment group. |
discount_function | character. If incorporating historical data, specify
the discount function. Currently supports the Weibull function
( |
y0_control | scalar. Number of events for the historical control arm. |
N0_control | scalar. Number of observations of the historical control group. |
alpha_max | scalar. Maximum weight the discount function can apply. Default is 1. For a two-arm trial, users may specify a vector of two values where the first value is used to weight the historical treatment group and the second value is used to weight the historical control group. |
fix_alpha | logical. Fix alpha at alpha_max? Default value is FALSE. |
weibull_scale | scalar. Scale parameter of the Weibull discount function
used to compute alpha, the weight parameter of the historical data. Default
value is 0.135. For a two-arm trial, users may specify a vector of two
values where the first value is used to estimate the weight of the
historical treatment group and the second value is used to estimate the
weight of the historical control group. Not used when
|
weibull_shape | scalar. Shape parameter of the Weibull discount function
used to compute alpha, the weight parameter of the historical data. Default
value is 3. For a two-arm trial, users may specify a vector of two values
where the first value is used to estimate the weight of the historical
treatment group and the second value is used to estimate the weight of the
historical control group. Not used when |
method | character. Analysis method with respect to estimation of the
weight parameter alpha. Default method |
.data | NULL. Stores the proportion of control and treatment. Should not be edited by the user. |
A list with historical data for control and treatment group with the discount function.
historical_binomial(y0_treatment = 5, N0_treatment = 10, y0_control = 15, N0_control = 23)#> $y0_treatment #> [1] 5 #> #> $N0_treatment #> [1] 10 #> #> $y0_control #> [1] 15 #> #> $N0_control #> [1] 23 #> #> $discount_function #> [1] "identity" #> #> $alpha_max #> [1] 1 #> #> $fix_alpha #> [1] FALSE #> #> $weibull_scale #> [1] 0.135 #> #> $weibull_shape #> [1] 3 #> #> $method #> [1] "fixed" #>historical_binomial(y0_treatment = 5, N0_treatment = 10, y0_control = 15, N0_control = 23, discount_function = "weibull", alpha_max = 1, fix_alpha = FALSE, weibull_scale = 0.135, weibull_shape = 3)#> $y0_treatment #> [1] 5 #> #> $N0_treatment #> [1] 10 #> #> $y0_control #> [1] 15 #> #> $N0_control #> [1] 23 #> #> $discount_function #> [1] "weibull" #> #> $alpha_max #> [1] 1 #> #> $fix_alpha #> [1] FALSE #> #> $weibull_scale #> [1] 0.135 #> #> $weibull_shape #> [1] 3 #> #> $method #> [1] "fixed" #>