Surv2 {intccr} | R Documentation |
Creating data frame
Description
The function Surv2
generates the survival object to be treated as the response from ciregic
.
Usage
Surv2(v, u, w = NULL, sub = NULL, event)
Arguments
v |
the last observation time prior to the failure; |
u |
the first observation time after the failure; |
w |
a left truncation time or delayed entry time. The default setting is |
sub |
an indicator variable in the data set. It is an optional argument for interval-censored competing risks data and missing cause of failure, and the default is |
event |
an indicator of cause of failure. If an observation is righ-censored, |
Details
The function Surv2
provides a response data frame which is used in the function ciregic
and ciregic_lt
. For interval-censored competing risks data, the function Surv2
must use three parameters (v, u, c
). For left-truncated and interval censored competing risks data, the function Surv2
must use four parameters (v, u, w, c
). If data are partially left-truncated, but all interval-censored, w = 0
for only interval-censored competing risks data.
Value
data frame
Author(s)
Jun Park, jun.park@alumni.iu.edu
Giorgos Bakoyannis, gbakogia@iu.edu
Examples
attach(simdata)
Surv2(v = v, u = u, event = c)
attach(simdata_lt)
Surv2(v = v, u = u, w = w, event = c)