residuals.reReg {reReg} | R Documentation |
Calculate Residuals for a ‘reReg’ Fit
Description
Calculates residuals for a joint frailty scale-change model fitted by 'reReg'.
Under the recurrent event model, at each observation time, ,
the residual is calculated as
The expected number of recurrent events at is calculated by the
cumulative rate function at
.
Under the failure time model, the residual is calculated as
where is the terminal event indicator and
is the cumulative hazard function at
.
Usage
## S3 method for class 'reReg'
residuals(object, model = c("recurrent", "failure"), ...)
Arguments
object |
an object of class |
model |
a character string specifying whether the residuals will be calculated under the recurrent event model or the failure time model. |
... |
additional parameters for future development. |
[Package reReg version 1.4.6 Index]