Simon_pr {VisualizeSimon2Stage} | R Documentation |
Simon_pr: Probabilities of a Simon's Two-Stage Design
Description
Probability of frail (i.e., early termination), fail (to reject the null) and success (to reject the null) of a Simon's two-stage design, at given true response rate(s).
Usage
Simon_pr(prob, n1, n, r1, r)
Arguments
prob |
|
n1 , n |
positive integer scalars, Stage-1 sample size |
r1 , r |
non-negative integer scalars, number of response
in Stage-1 |
Details
Given the Simon's two-stage design (n_1, r_1, n, r)
, for a response rate
p
, we have the number of Stage-1 positive responses X_1 \sim \textrm{Binom}(n_1, p)
and the number of Stage-2 positive responses X_2 \sim \textrm{Binom}(n-n_1, p)
.
Obviously X_1
and X_2
are independent.
The probability of early termination is \textrm{Pr}(X_1 \leq r_1)
.
The probability of failure to reject H_0
is
\sum_{s_1 = r_1+1}^{n_1} \textrm{Pr}(X_1=s_1)\cdot\textrm{Pr}(X_2 \leq (r-s_1))
The probability of rejecting H_0
is
\sum_{s_1 = r_1+1}^{n_1} \textrm{Pr}(X_1=s_1)\cdot\textrm{Pr}(X_2 > (r-s_1))
Parameters nomenclature of n1
, n
, r1
and r
follows that of
PASS and function ph2simon.
Value
Simon_pr returns Simon_pr object.
Slots
.Data
ncol-3 double matrix, probability of frail (i.e., early termination), fail (to reject the null) and success (to reject the null), at each response rate
p
given in@prob
eN
numeric vector, expected sample size(s)
\textrm{E}(N)
for each of response rate(s)p
prob
Examples
Simon_pr(prob = c(.2, .4), n1 = 15L, r1 = 3L, n = 24L, r = 7L)