Usage
simLRdata(n,max.c,pi.x,pi.r,pi.z,
mean.NR.1,mean.NR.2,mean.R.1,mean.R.2,
mean.RE.11,mean.RE.12,mean.RE.21,mean.RE.22)
Arguments
n
total number of subjects participating in the clinical trial
max.c
censoring time C is generated from uniform(0, 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
mean.NR.1
for patients who are assigned to A1 (X=0) and do not respond (R=0), a survival time T.NR.1 is drawn from exponential(1/mean.NR.1) with mean equal to mean.NR.1
mean.NR.2
for patients who are assigned to A2 (X=1) and do not respond (R=0), a survival time T.NR.2 is drawn from exponential(1/mean.NR.2) with mean equal to mean.NR.2
mean.R.1
for patients who are assigned to A1 (X=0) and respond (R=1), time to response T.R.1 is drawn from exponential(1/mean.R.1) with mean equal to mean.R.1
mean.R.2
for patients who are assigned to A2 (X=1) and respond (R=1), time to response T.R.2 is drawn from exponential(1/mean.R.2) with mean equal to mean.R.2
mean.RE.11
for patients who are assigned to A1 (X=0), respond (R=1), and then assigned to B1 (Z=0), a time from response to event is generated from exponential(1/mean.RE.11) with mean equal to mean.RE.11
mean.RE.12
for patients who are assigned to A1 (X=0), respond (R=1), and then assigned to B2 (Z=1), a time from response to event is generated from exponential(1/mean.RE.12) with mean equal to mean.RE.12
mean.RE.21
for patients who are assigned to A2 (X=1), respond (R=1), and then assigned to B1 (Z=0), a time from response to event is generated from exponential(1/mean.RE.21) with mean equal to mean.RE.21
mean.RE.22
for patients who are assigned to A2 (X=1), respond (R=1), and then assigned to B2 (Z=1), a time from response to event is generated from exponential(1/mean.RE.22) with mean equal to mean.RE.22