gs_power_ahr.RdGroup sequential design power using average hazard ratio under non-proportional hazards
gs_power_ahr( enrollRates = tibble::tibble(Stratum = "All", duration = c(2, 2, 10), rate = c(3, 6, 9)), failRates = tibble::tibble(Stratum = "All", duration = c(3, 100), failRate = log(2)/c(9, 18), hr = c(0.9, 0.6), dropoutRate = rep(0.001, 2)), ratio = 1, events = c(30, 40, 50), analysisTimes = NULL, binding = FALSE, upper = gs_b, upar = gsDesign(k = length(events), test.type = 1, n.I = events, maxn.IPlan = max(events), sfu = sfLDOF, sfupar = NULL)$upper$bound, lower = gs_b, lpar = c(qnorm(0.1), rep(-Inf, length(events) - 1)), test_upper = TRUE, test_lower = TRUE, r = 18, tol = 1e-06 )
| enrollRates | enrollment rates |
|---|---|
| failRates | failure and dropout rates |
| ratio | Experimental:Control randomization ratio (not yet implemented) |
| events | Targeted events at each analysis |
| analysisTimes | Minimum time of analysis |
| binding | indicator of whether futility bound is binding; default of FALSE is recommended |
| upper | Function to compute upper bound |
| upar | Parameter passed to |
| lower | Function to compute lower bound |
| lpar | Parameter passed to |
| test_upper | indicator of which analyses should include an upper (efficacy) bound; single value of TRUE (default) indicates all analyses;
otherwise, a logical vector of the same length as |
| test_lower | indicator of which analyses should include an lower bound; single value of TRUE (default) indicates all analyses;
single value FALSE indicated no lower bound; otherwise, a logical vector of the same length as |
| r | Integer, at least 2; default of 18 recommended by Jennison and Turnbull |
| tol | Tolerance parameter for boundary convergence (on Z-scale) |
a tibble with columns Analysis, Bound, Z, Probability, theta, Time, AHR, Events.
Contains a row for each analysis and each bound.
Bound satisfy input upper bound specification in upper, upar and lower bound specification in lower, lpar.
The AHR() function computes statistical information at targeted event times.
The tEvents() function is used to get events and average HR at targeted analysisTimes.
#> # A tibble: 4 x 10 #> Analysis Bound Time Events Z Probability AHR theta info info0 #> <int> <chr> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> #> 1 1 Upper 14.9 30.0 2.67 0.0219 0.787 0.240 7.37 7.50 #> 2 2 Upper 19.2 40.0 2.29 0.0885 0.744 0.295 9.79 10.0 #> 3 3 Upper 24.5 50.0 2.03 0.206 0.713 0.339 12.2 12.5 #> 4 1 Lower 14.9 30.0 -1.28 0.0266 0.787 0.240 7.37 7.50# 2-sided symmetric O'Brien-Fleming spending bound gs_power_ahr(analysisTimes = c(12, 24, 36), binding = TRUE, upper = gs_spending_bound, upar = list(sf = gsDesign::sfLDOF, total_spend = 0.025, param = NULL, timing = NULL, theta=0), lower = gs_spending_bound, lpar = list(sf = gsDesign::sfLDOF, total_spend = 0.025, param = NULL, timing = NULL, theta=0))#> # A tibble: 6 x 10 #> Analysis Bound Time Events Z Probability AHR theta info info0 #> <int> <chr> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> #> 1 1 Upper 14.9 30.0 3.13 0.00656 0.787 0.240 7.37 7.50 #> 2 2 Upper 24 49.1 2.37 0.114 0.715 0.335 12.0 12.3 #> 3 3 Upper 36 66.2 2.01 0.323 0.683 0.381 16.3 16.6 #> 4 1 Lower 14.9 30.0 -2.48 0.000871 0.787 0.240 7.37 7.50 #> 5 2 Lower 24 49.1 -1.21 0.00906 0.715 0.335 12.0 12.3 #> 6 3 Lower 36 66.2 -0.474 0.0250 0.683 0.381 16.3 16.6