Bai Hu Shen's Urn {grouprar} | R Documentation |
Bai Hu Shen's Urn
Description
Bai, Hu, and Shen bai2002adaptive proposed a new adaptive design for multi-arm clinical trials. The main idea behind this procedure is that the allocation probability adapts based on the performance of the most recent patients under their assigned treatment. Positive performance in that treatment increase the likelihood of the next patient being assigned to this group, whereas negative outcomes decrease it. This function is for simulating the Bai, Hu, and Shen's urn model under two-sided hypothesis testing in clinical trial context.
Usage
Bai.Hu.Shen.Urn(k, p, ssn, Y0 = NULL, nsim = 2000, alpha = 0.05)
Arguments
k |
a positive integer. The value specifies the number of treatment groups involved in a clinical trial. ( |
p |
a positive vector of length equals to |
ssn |
a positive integer. The value specifies the total number of participants involved in each round of the simulation. |
Y0 |
A vector of length |
nsim |
a positive integer. The value specifies the total number of simulations, with a default value of 2000. |
alpha |
A number between 0 and 1. The value represents the predetermined level of significance that defines the probability threshold for rejecting the null hypothesis, with a default value of 0.05. |
Details
Bai, Hu and Shen's urn can be describe as follows: An urn contains K
types of balls initially. Balls of types 1, 2, \cdots, K
represent treatments 1, 2, \cdots, K
. A type k
ball is drawn randomly from the urn, and then we assign the patient, who is waiting to be assigned, to the treatment k
. After obtaining the response, we may adapt the composition of the urn. A success on treatment k
adds a ball of type of $k$ to the urn and a failure on treatment k
adds \frac{p_i}{(M-p_k)}
ball for each of the other K-1
types, where M = p_1 + ... + p_K
.
Value
name |
The name of procedure. |
parameter |
The true parameters used to do the simulations. |
assignment |
The randomization sequence. |
propotion |
Average allocation porpotion for each of treatment groups. |
failRate |
The proportion of individuals who do not achieve the expected outcome in each simulation, on average. |
pwClac |
The probability of the study to detect a significant difference or effect if it truly exists. |
k |
Number of arms involved in the trial. |
References
Bai Z D, Hu F, Shen L. An adaptive design for multi-arm clinical trials[J]. Journal of Multivariate Analysis, 2002, 81(1): 1-18.
Examples
## a simple use
bhs.res = Bai.Hu.Shen.Urn(k = 3,
p = c(0.7, 0.8, 0.6),
ssn = 500,
Y0 = NULL,
nsim = 200,
alpha = 0.05)
## view the output
bhs.res
## view all simulation settings
bhs.res$name
bhs.res$parameter
bhs.res$k
## View the simulations results
bhs.res$propotion
bhs.res$failRate
bhs.res$pwCalc
bhs.res$assignment