CHR: Integrated squared distance (ISD) between empirical and...

View source: R/CHR.R

CHRR Documentation

Integrated squared distance (ISD) between empirical and theoretical CHRs.

Description

Integrated squared distance (ISD) between empirical and theoretical CHRs

Usage

CHR(formula, data, n = 5)

Arguments

formula

a formula object, with the response on the left of a ~ operator, and the terms on the right. The response must be a survival object as returned by the Surv function. The RHS must contain a 'cluster' term.

data

a data.frame containing the variables in the model.

n

Number of steps for empirical CHR.

Details

The CHR and the bivariate survival function are estimated seperately. The ISD between the empirical CHR (as a function of the bivariate survival function) and the ones implied by the different frailty models, is estimated. The function returns the estimates sorted from lowest (best) to highest (worst). It is possible to get a very nice plot of the empiricaly estimated function and the parametric ones with autoplot.

Value

Data.frame with ISD for different frailty distributions.

Author(s)

Jeppe E. H. Madsen <jeppe.ekstrand.halkjaer@gmail.com>

References

Bandeen-Roche, Karen. "A diagnostic for association in bivariate survival models." Lifetime Data Analysis 11.2 (2005): 245-264.

See Also

autoplot.CHR

logLikSort autoplot.CHR

Examples

library(survival)
data("diabetic")
CHR(Surv(time,status) ~ cluster(id), data = diabetic)

Jeepen/biSurv documentation built on Sept. 30, 2023, 3:55 a.m.