Given a data frame with one row per subject containing event times and a data frame containing time points at which a time-dependent covariate changes its value, returns the unique time at which either event occurs or a time-dependent covariate changes its value.
combine_cut(event_df, tdc_df, time_var, status_var, tz_var, cens_value = 0)
A data frame containing information on time-dependent variables
in long format. Needs to contain a "time" variable indicating when the
TDCs change their value. Must have same name as variable indicating event
times in event_df
.
A character, specifies the column of the event or
censoring time in event_df
and the time of measurement for
the time-dependent covariates in tdc_df
.
As time_var
, but specifies column containing the
event indicator. Can be missing in the tdc_df
.
The value that indicates censoring in the
status_var
column.