Dataset toydata contains repeated measurements made in 3 patients. It mimics randomized clinical trials data with two parallel arms with a repeated measurement of a time-varying binary covariate, which could be the time-varying confounder acting both on the survival and treatment censoring.
data("toydata")A data frame with 3 observations on the following 12 variables.
ida numeric vector corresponding to the patient's identifier
randta vector containing the date of the randomization visit
lastdta vector containing the date of latest news
statusa numeric vector. The value equals to 1 if the patient dies at lastdt (and 0 otherwise)
agea numeric vector containing patient<U+2019>s age (in years) at randomization
ps1a numeric vector containing the values (0 or 1) of a repeated measurement
happening on date randt. Note that some of them could be missing
ps2a numeric vector containing the values (0 or 1) of a repeated measurement
happening on date dt2. Note that some of them could be missing
ps3a numeric vector containing the values (0 or 1) of a repeated measurement
happening on date dt3. Note that some of them could be missing
dt2a vector containing the dates of measurement
of ps2. Note that some of them could be missing
dt3a vector containing the date of measurement
ps3. Note that some of them could be missing
arma vector containing the patient<U+2019>s randomized arm
swtrtdta vector containing the date when the patient initiates the other arm treatment (NA if does not happen)
Graffeo, N., Latouche, A., Le Tourneau C., Chevret, S. "An R Package for IPCW: Application to switches in clinical trials" (submitted)
# NOT RUN {
data(toydata)
toydata
# }
Run the code above in your browser using DataLab