simon2stage | R Documentation |
Obtains Simon's two-stage minimax, admissible, and optimal designs.
simon2stage(
alpha = NA_real_,
beta = NA_real_,
piH0 = NA_real_,
pi = NA_real_,
n_max = 110L
)
alpha |
Type I error rate (one-sided). |
beta |
Type II error rate (1-power). |
piH0 |
Response probability under the null hypothesis. |
pi |
Response probability under the alternative hypothesis. |
n_max |
Upper limit for sample size, defaults to 110. |
A data frame containing the following variables:
piH0
: Response probability under the null hypothesis.
pi
: Response probability under the alternative hypothesis.
alpha
: The specified one-sided significance level.
beta
: The specified type II error.
n
: Total sample size.
n1
: Stage 1 sample size.
r1
: Futility boundary for stage 1.
r
: Futility boundary for stage 2.
EN0
: Expected sample size under the null hypothesis.
attainedAlpha
: Attained type 1 error.
power
: Attained power.
PET0
: Probability of early stopping under the null hypothesis.
w_lower
: Lower bound of the interval for w
.
w_upper
: Upper bound of the interval for w
.
design
: Description of the design, e.g., minimax, admissible,
or optimal.
Here w
is the weight in the objective function:
w*n + (1-w)*EN0
.
Kaifeng Lu, kaifenglu@gmail.com
simon2stage(0.05, 0.2, 0.1, 0.3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.