Usage
simCHRdata(n,max.c,pi.x,pi.r,pi.z,gamma10,
gamma11,gamma12,gamma20,gamma21,gamma22,alpha10,
alpha11,alpha12,alpha20,alpha21,alpha22,beta)
Arguments
n
total number of subjects participating in the clinical trial
max.c
censoring time C is generated from uniform(max.c/2, max.c)
pi.x
the probability of being assigned to A2 at the first stage. The first-stage treatment indicator X is generated from Bernoulli(pi.x). X=0 if assigned to A1 at the first stage, and X=1 if assigned to A2 at the first stage.
pi.r
the probability of response. Response status R is generated from Bernoulli(pi.r)
pi.z
the probability of being assigned to B2 among responders. The second-stage treatment indicator Z is generated from Bernoulli(pi.z) among responders (R=1). Z=0 if assigned to B1 at the second stage, and Z=1 if assigned to B2 at the second stage. For non-re
gamma10
for individuals who are assigned to A1 at first-stage, and do not respond, survival times are drawn from Weibull distribution with parameters alpha10 and gamma10
gamma11
for individuals who are assigned to A1 at first-stage, respond to A1, and are assigned to B1 at second-stage, survival times are drawn from Weibull distribution with parameters alpha11 and gamma11
gamma12
for individuals who are assigned to A1 at first-stage, respond to A1, and are assigned to B2 at second-stage, survival times are drawn from Weibull distribution with parameters alpha12 and gamma12
gamma20
for individuals who are assigned to A2 at first-stage, and do not respond, survival times are drawn from Weibull distribution with parameters alpha20 and gamma20
gamma21
for individuals who are assigned to A2 at first-stage, respond to A2, and are assigned to B1 at second-stage, survival times are drawn from Weibull distribution with parameters alpha21 and gamma21
gamma22
for individuals who are assigned to A2 at first-stage, respond to A2, and are assigned to B2 at second-stage, survival times are drawn from Weibull distribution with parameters alpha22 and gamma22
alpha10
for individuals who are assigned to A1 at first-stage, and do not respond, survival times are drawn from Weibull distribution with parameters alpha10 and gamma10
alpha11
for individuals who are assigned to A1 at first-stage, respond to A1, and are assigned to B1 at second-stage, survival times are drawn from Weibull distribution with parameters alpha11 and gamma11
alpha12
for individuals who are assigned to A1 at first-stage, respond to A1, and are assigned to B2 at second-stage, survival times are drawn from Weibull distribution with parameters alpha12 and gamma12
alpha20
for individuals who are assigned to A2 at first-stage, and do not respond, survival times are drawn from Weibull distribution with parameters alpha20 and gamma20
alpha21
for individuals who are assigned to A2 at first-stage, respond to A2, and are assigned to B1 at second-stage, survival times are drawn from Weibull distribution with parameters alpha21 and gamma21
alpha22
for individuals who are assigned to A2 at first-stage, respond to A2, and are assigned to B2 at second-stage, survival times are drawn from Weibull distribution with parameters alpha22 and gamma22
beta
the coefficient vector for two covariates V1 and V2, for example, beta=c(0.5,0.5). Both covariates V1 and V2 are generated from Bernoulli(0.5)