cfc.survreg: Cause-specific competing-risk survival analysis, using...

Description Usage Arguments Value Author(s) See Also Examples

View source: R/cfc_survreg.R

Description

Convenient function to build cause-specific, parametric survival models using the survival package. This is followed by application of cfc function to produce cumulative incidence functions.

Usage

1
2
3
cfc.survreg(formula, data, newdata = NULL, dist = "weibull"
  , control = survreg.control(), tout, Nmax = 100L
  , rel.tol = 1e-05)

Arguments

formula

Survival formula with a multi-state status variable. See cfc.prepdata.

data

Data frame containing variables listed in formula.

newdata

Data frame of structure similar to data, perhaps without the time and status columns, to be used for generating cumulative incidence curves.

dist

One of survreg.distributions. It can also be a vector, in which case elements 1 through K (number of causes) will be extracted and assigned to each cause-specific survival model. This allows for using different distributions for different causes.

control

List of survreg control parameters, according to survreg.control.

tout

Time points, along which to produce the cumulative incidence curves.

Nmax

Maximum number of subdivisions to be used in the cfc quadrature algorithm.

rel.tol

Threshold for relative error in cfc quadrature, used as a stoppage criterion. See cfc for details.

Value

A list with the following elements:

K

Number of causes.

formulas

List of formulas used in each of the K cause-specific survival regression models.

regs

List of all cause-specific regression objects returned by survreg, one per cause. The x field of each regression object has been substituted by the model matrix from newdata.

tout

Same as input.

cfc

An object of class cfc, the output of applying cfc to the parametric survival regression models constructed using survreg from survival package.

Author(s)

Mansour T.A. Sharabiani, Alireza S. Mahani

See Also

cfc.prepdata, cfc

Examples

1
2
3
4
data(bmt)
formul <- Surv(time, cause) ~ platelet + age + tcell
ret <- cfc.survreg(formul, bmt[1:300, ], bmt[-(1:300), ]
  , Nmax = 300, rel.tol = 1e-3)

CFC documentation built on June 21, 2017, 5:03 p.m.