# Simple: enter a vector of length 3 for bound
gs_b(par = 4:2)
# 2nd element of par
gs_b(par = 4:2, k = 2)
# Generate an efficacy bound using a spending function
# Use Lan-DeMets spending approximation of O'Brien-Fleming bound
# as 50%, 75% and 100% of final spending
# Information fraction
IF <- c(.5, .75, 1)
gs_b(par = gsDesign::gsDesign(
alpha = .025, k = length(IF),
test.type = 1, sfu = gsDesign::sfLDOF,
timing = IF
)$upper$bound)
Run the code above in your browser using DataLab