Description Usage Arguments Value Author(s) References Examples
First the starting and stopping TC intervals are determined according to the expected event criteria; ITC intervals are truncated if necessary or dropped if meaningless. Next the dataset is broken up according to the TC intervals.Finally, the dataset is compressed to only the meaningful intervals.
| 1 2 3 | addtc(dataset, ncov, maxfollow, start_times, stop_times, min_future_events, numevents,
 nperson, nmaxint, maxobs, interval_width, nitc_start, itc_start_endpoint, nitc_stop,
 itc_stop_endpoint, tti, tts, followup)
 | 
| dataset | data.frame organized as expected by tc() | 
| ncov | number of baseline covariates (including treatment) to be included in model | 
| maxfollow | maximum followup for any subject in dataset | 
| start_times | vector of ordered times when starting of treatment occurs in dataset | 
| stop_times | vector of ordered times when stopping of treatment occurs in dataset | 
| min_future_events | minimum number of events expected of future starters(stoppers) of treatment for determining upper bound on starting(stopping) TC intervals | 
| numevents | number of events in dataset | 
| nperson | number of subjects in dataset | 
| nmaxint | maximum number of TC intervals allowed | 
| maxobs | maximum number of observations (intervals of time) allowed for dataset | 
| interval_width | width of the TC intervals | 
| nitc_start | number of ITC starting intervals | 
| itc_start_endpoint | vector containing the endpoints of the ITC starting intervals | 
| nitc_stop | number of ITC stopping intervals | 
| itc_stop_endpoint | Vector containing the endpoints of the ITC starting intervals | 
| tti | vector of same length as dataset containing times when starting occurs or 0 if subject does not start | 
| tts | vector of same length as dataset containing times when stopping occurs or 0 if subject does not stop | 
| followup | vector of same length as dataset containing followup times | 
| dataset  | data.frame with dataset broken up according to TC intervals | 
| tstartp  | matrix whose columns are the ITC starting covariate values | 
| tstopp  | matrix whose columns are the ITC stopping covariate values | 
| nstartint  | number of TC starting intervals | 
| startint  | vector containing the TC starting interval endpoints | 
| nstopint  | number of TC stopping intervals | 
| stopint  | vector containing the TC stopping interval endpoints | 
| nitc_start  | number of ITC starting intervals | 
| itc_start_endpoint  | vector containing the ITC starting interval endpoints | 
| nitc_stop  | number of ITC stopping intervals | 
| itc_stop_endpoint  | vector containing the ITC stopping interval endpoints | 
James F. Troendle
Troendle, JF, Leifer, E, Zhang Z, Yang, S, and Tewes H (2017) How to Control for Unmeasured Confounding in an Observational Time-To-Event Study With Exposure Incidence Information: the Treatment Choice Cox Model. Statistics in Medicine 36: 3654-3669.
| 1 2 3 4 5 6 7 8 | ##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.
## The function is currently defined as
function (x)
{
  }
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.