Title: | Simulations for Response Adaptive Block Randomization Design |
---|---|
Description: | Conduct simulations of the Response Adaptive Block Randomization (RABR) design to evaluate its type I error rate, power and operating characteristics for binary and continuous endpoints. For more details of the proposed method, please refer to Zhan et al. (2021) <https://doi.org/10.1002/sim.9104>. |
Authors: | Tianyu Zhan [aut, cre] |
Maintainer: | Tianyu Zhan <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1.1 |
Built: | 2025-02-26 04:33:27 UTC |
Source: | https://github.com/tian-yu-zhan/rabr |
Simulate RABR for binary endpoints to evaluate operating characteristics
RABRbinary( RateVec, M, N, R, Nitt, Alpha, Ncluster = 1, Seed = 12345, MultiMethod )
RABRbinary( RateVec, M, N, R, Nitt, Alpha, Ncluster = 1, Seed = 12345, MultiMethod )
RateVec |
Vector of response rate for placebo and active treatment groups. |
M |
Total sample size of burn-in period. |
N |
Total sample size of RABR. Must be larger than M. |
R |
Randomization vector for placebo and active treatment groups. |
Nitt |
Number of simulation iterations. |
Alpha |
One-sided significance level. |
Ncluster |
Number of clusters for parallel computing. |
Seed |
Random seed. |
MultiMethod |
Multiplicity adjustment method. Must be one of the following values "holm", "hochberg", "hommel", "bonferroni", or "dunnett". |
The RateVec
is a vector of response rate for placebo and active treatment groups. The current package supports 2 or 3 active treatment groups. Note that a larger response corresponds to a better outcome.
The M
is the total sample size of burn-in period with equal randomization. The total sample size N
should be larger than N. The choice of M
can be selected by comparing simulations from several candidate values. The R
is a pre-specified randomization vector, where the first element is for placebo, and the next one for the best performing group, up to the worst performing group.
The Alpha
is the one-sided significance level. The MultiMethod
can be set at "holm" for Holm, "hochberg" for Hochberg, "hommel" for Hommel, "bonferroni" for Bonferroni, or "dunnett" for Dunnett procedures.
ProbUnadj: Probability of rejecting each elementary null hypothesis without multiplicity adjustment
ProbAdj: Probability of rejecting each elementary null hypothesis with multiplicity adjustment
ProbAdjSelected: Probability of selecting and confirming the efficacy of each active treatment group
ProbAdjOverall: Probability of rejecting at least one elementary null hypothesis with multiplicity adjustment
ASN: Average sample size of placebo and active treatment groups
Tianyu Zhan ([email protected])
Zhan, T., Cui, L., Geng, Z., Zhang, L., Gu, Y., & Chan, I. S. (2021). A practical response adaptive block randomization (RABR) design with analytic type I error protection. Statistics in Medicine, 40(23), 4947-4960.
Cui, L., Zhan, T., Zhang, L., Geng, Z., Gu, Y., & Chan, I. S. (2021). An automation-based adaptive seamless design for dose selection and confirmation with improved power and efficiency. Statistical Methods in Medical Research, 30(4), 1013-1025.
## Consider an example with two active treatment ## groups and a placebo. Suppose that the response ## rate of placebo is 0.15, 0.28 and 0.4 for ## two active treatment groups. The total sample ## size is N = 180 with a burn-in period M = 90. We ## use the randomization vector of (7, 7, 1), ## which means that placebo, the better performing ## group, and the worse group have randomization ## probabilities 7/15, 7/15, 1/15 respectively. ## The one-sided significance level is 2.5%. ## Nitt = 100 is for demonstration, and should be ## increased to 10^5 in practice. ## library(parallel) library(doParallel) RABR.fit = RABRbinary( RateVec = c(0.15, 0.28, 0.4), M = 90, N = 180, R = c(7, 7, 1), Nitt = 100, Alpha = 0.025, Ncluster = 2, Seed = 12345, MultiMethod = "bonferroni") ## ## Probability of rejecting each elementary null ## hypothesis without multiplicity adjustment print(RABR.fit$ProbUnadj) ## ## Probability of rejecting each elementary null ## hypothesis with multiplicity adjustment print(RABR.fit$ProbAdj) ## ## Probability of selecting and confirming the ## efficacy of each active treatment group print(RABR.fit$ProbAdjSelected) ## ## ProbAdjOverall Probability of rejecting at ## least one elementary null hypothesis ## with multiplicity adjustment print(RABR.fit$ProbAdjOverall) ## ## ASN Average sample size of placebo and active ## treatment groups print(RABR.fit$ASN)
## Consider an example with two active treatment ## groups and a placebo. Suppose that the response ## rate of placebo is 0.15, 0.28 and 0.4 for ## two active treatment groups. The total sample ## size is N = 180 with a burn-in period M = 90. We ## use the randomization vector of (7, 7, 1), ## which means that placebo, the better performing ## group, and the worse group have randomization ## probabilities 7/15, 7/15, 1/15 respectively. ## The one-sided significance level is 2.5%. ## Nitt = 100 is for demonstration, and should be ## increased to 10^5 in practice. ## library(parallel) library(doParallel) RABR.fit = RABRbinary( RateVec = c(0.15, 0.28, 0.4), M = 90, N = 180, R = c(7, 7, 1), Nitt = 100, Alpha = 0.025, Ncluster = 2, Seed = 12345, MultiMethod = "bonferroni") ## ## Probability of rejecting each elementary null ## hypothesis without multiplicity adjustment print(RABR.fit$ProbUnadj) ## ## Probability of rejecting each elementary null ## hypothesis with multiplicity adjustment print(RABR.fit$ProbAdj) ## ## Probability of selecting and confirming the ## efficacy of each active treatment group print(RABR.fit$ProbAdjSelected) ## ## ProbAdjOverall Probability of rejecting at ## least one elementary null hypothesis ## with multiplicity adjustment print(RABR.fit$ProbAdjOverall) ## ## ASN Average sample size of placebo and active ## treatment groups print(RABR.fit$ASN)
Simulate RABR for continuous endpoints to evaluate operating characteristics
RABRcontinuous( MeanVec, SdVec, M, N, R, Nitt, Alpha, Ncluster = 1, Seed = 12345, MultiMethod )
RABRcontinuous( MeanVec, SdVec, M, N, R, Nitt, Alpha, Ncluster = 1, Seed = 12345, MultiMethod )
MeanVec |
Vector of response mean for placebo and active treatment groups. |
SdVec |
Vector of standard deviation for placebo and active treatment groups. |
M |
Total sample size of burn-in period. |
N |
Total sample size of RABR. Must be larger than M. |
R |
Randomization vector for placebo and active treatment groups. |
Nitt |
Number of simulation iterations. |
Alpha |
One-sided significance level. |
Ncluster |
Number of clusters for parallel computing. |
Seed |
Random seed. |
MultiMethod |
Multiplicity adjustment method. Must be one of the following values "holm", "hochberg", "hommel", "bonferroni", or "dunnett". |
The MeanVec
is a vector of response mean for placebo and active treatment groups, while SdVec
is for standard deviation. They should be with the same length. The current package supports 2 or 3 active treatment groups. Note that a larger response corresponds to a better outcome.
The M
is the total sample size of burn-in period with equal randomization. The total sample size N
should be larger than N. The choice of M
can be selected by comparing simulations from several candidate values. The R
is a pre-specified randomization vector, where the first element is for placebo, and the next one for the best performing group, up to the worst performing group.
The Alpha
is the one-sided significance level. The MultiMethod
can be set at "holm" for Holm, "hochberg" for Hochberg, "hommel" for Hommel, "bonferroni" for Bonferroni, or "dunnett" for Dunnett procedures.
ProbUnadj: Probability of rejecting each elementary null hypothesis without multiplicity adjustment
ProbAdj: Probability of rejecting each elementary null hypothesis with multiplicity adjustment
ProbAdjSelected: Probability of selecting and confirming the efficacy of each active treatment group
ProbAdjOverall: Probability of rejecting at least one elementary null hypothesis with multiplicity adjustment
ASN: Average sample size of placebo and active treatment groups
Tianyu Zhan ([email protected])
Zhan, T., Cui, L., Geng, Z., Zhang, L., Gu, Y., & Chan, I. S. (2021). A practical response adaptive block randomization (RABR) design with analytic type I error protection. Statistics in Medicine, 40(23), 4947-4960.
Cui, L., Zhan, T., Zhang, L., Geng, Z., Gu, Y., & Chan, I. S. (2021). An automation-based adaptive seamless design for dose selection and confirmation with improved power and efficiency. Statistical Methods in Medical Research, 30(4), 1013-1025.
## Consider an example with three active treatment ## groups and a placebo. Suppose that the response ## mean for placebo is 0.43 and 0.48, 0.63, and 1.2 ## for three active treatment groups. The standard ## deviation is 1 for all groups. The total sample ## size is N = 120 with a burn-in period M = 60. We ## use the randomization vector of (8, 9, 2, 1), ## which means that placebo, the best performing ## group, the second-best group, and the worst group ## have randomization probabilities 8/20, 9/20, 2/20 ## 1/20, respectively. The one-sided significance ## level is considered at 2.5%. Nitt = 100 is for ## demonstration, and should be increased to 10^5 ## in practice. ## library(parallel) library(doParallel) RABR.fit = RABRcontinuous( MeanVec = c(0.43, 0.48, 0.63, 1.2), SdVec = c(1, 1, 1, 1), M = 60, N = 120, R = c(8, 9, 2, 1), Nitt = 100, Alpha = 0.025, Ncluster = 2, Seed = 12345, MultiMethod = "dunnett") ## ## Probability of rejecting each elementary null ## hypothesis without multiplicity adjustment print(RABR.fit$ProbUnadj) ## ## Probability of rejecting each elementary null ## hypothesis with multiplicity adjustment print(RABR.fit$ProbAdj) ## ## Probability of selecting and confirming the ## efficacy of each active treatment group print(RABR.fit$ProbAdjSelected) ## ## ProbAdjOverall Probability of rejecting at ## least one elementary null hypothesis ## with multiplicity adjustment print(RABR.fit$ProbAdjOverall) ## ## ASN Average sample size of placebo and active ## treatment groups print(RABR.fit$ASN)
## Consider an example with three active treatment ## groups and a placebo. Suppose that the response ## mean for placebo is 0.43 and 0.48, 0.63, and 1.2 ## for three active treatment groups. The standard ## deviation is 1 for all groups. The total sample ## size is N = 120 with a burn-in period M = 60. We ## use the randomization vector of (8, 9, 2, 1), ## which means that placebo, the best performing ## group, the second-best group, and the worst group ## have randomization probabilities 8/20, 9/20, 2/20 ## 1/20, respectively. The one-sided significance ## level is considered at 2.5%. Nitt = 100 is for ## demonstration, and should be increased to 10^5 ## in practice. ## library(parallel) library(doParallel) RABR.fit = RABRcontinuous( MeanVec = c(0.43, 0.48, 0.63, 1.2), SdVec = c(1, 1, 1, 1), M = 60, N = 120, R = c(8, 9, 2, 1), Nitt = 100, Alpha = 0.025, Ncluster = 2, Seed = 12345, MultiMethod = "dunnett") ## ## Probability of rejecting each elementary null ## hypothesis without multiplicity adjustment print(RABR.fit$ProbUnadj) ## ## Probability of rejecting each elementary null ## hypothesis with multiplicity adjustment print(RABR.fit$ProbAdj) ## ## Probability of selecting and confirming the ## efficacy of each active treatment group print(RABR.fit$ProbAdjSelected) ## ## ProbAdjOverall Probability of rejecting at ## least one elementary null hypothesis ## with multiplicity adjustment print(RABR.fit$ProbAdjOverall) ## ## ASN Average sample size of placebo and active ## treatment groups print(RABR.fit$ASN)