View source: R/groupRAR_tools.R
| sqMonitor | R Documentation |
sqMonitor specifies the interim looks and the alpha spending function of a group sequential design, to be passed as the monitor argument of DBCD_Bin, DBCD_Cont, Group.DBCD_Bin and Group.DBCD_Cont. sqBoundary computes the corresponding two-sided boundaries for the standardized test statistic.
sqMonitor(t, spend = "OBF")
sqBoundary(t, alpha = 0.05, spend = "OBF")
t |
A numeric vector of information times in (0, 1], the fraction of the total sample size at which the looks are taken. The final analysis at |
spend |
The alpha spending function. One of |
alpha |
A number between 0 and 1. The overall two-sided significance level, with a default value of 0.05. |
The spending functions of Lan and DeMets (1983) are used, with each tail spending the one-sided function at level \alpha/2 (Proschan, Lan and Wittes, 2006), as in Zhu and Hu (2010). For one tail at level a = \alpha/2 they are 2\{1 - \Phi(z_{a/2}/\sqrt{t})\} for "OBF", a\log\{1 + (e - 1)t\} for "Pocock" and a t for "Linear". The boundary c_j of look j is chosen so that, under the null hypothesis, the probability that |Z| first reaches the boundary at look j equals the alpha spent between looks j-1 and j, where Z at the information times t_1 < t_2 < \cdots is a standard normal process with correlation \sqrt{t_i/t_j}. Zhu and Hu (2010) showed that the sequential test statistics of a two-arm trial randomized by the doubly adaptive biased coin design have asymptotically this structure, so these boundaries keep the type I error. The boundaries are computed by recursive numerical integration of the density of Z\sqrt{t} over the continuation region (Armitage, McPherson and Rowe, 1969), which is fast for any number of looks.
Sequential monitoring is available for two arms only, because the theory of Zhu and Hu (2010) covers the comparison of two treatments.
sqMonitor returns an object of class "sqMonitor", a list with the sorted information times t and the spending function spend.
sqBoundary returns a numeric vector with the boundary for |Z| at each look, named look 1, look 2, ... A boundary is Inf if no alpha is spent at that look.
Lan, K. K. G. and DeMets, D. L. (1983). Discrete sequential boundaries for clinical trials. Biometrika, 70(3), 659-663. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1093/biomet/70.3.659")}
Armitage, P., McPherson, C. K. and Rowe, B. C. (1969). Repeated significance tests on accumulating data. Journal of the Royal Statistical Society, Series A, 132(2), 235-244. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.2307/2343787")}
Proschan, M. A., Lan, K. K. G. and Wittes, J. T. (2006). Statistical Monitoring of Clinical Trials: A Unified Approach. Springer.
Zhu, H. and Hu, F. (2010). Sequential monitoring of response-adaptive randomized clinical trials. The Annals of Statistics, 38(4), 2218-2241. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1214/10-AOS796")}
DBCD_Bin, DBCD_Cont, Group.DBCD_Bin, Group.DBCD_Cont.
## the boundaries of Zhu and Hu (2010): 4.877, 2.963 and 1.969
sqBoundary(c(0.2, 0.5, 1), alpha = 0.05, spend = "OBF")
sqBoundary(c(0.2, 0.5, 1), alpha = 0.05, spend = "Pocock")
## two interim looks after 1/3 and 2/3 of the patients
m <- sqMonitor(c(1/3, 2/3), spend = "OBF")
res <- DBCD_Bin(n0 = 20, p = c(0.6, 0.8), k = 2, ssn = 150, target.alloc = "RSIHR",
nsim = 30, monitor = m, seed = 1)
res[["stopping probability"]]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.