Inf.Cval.Delta: Inference of Delta C

Description Usage Arguments Value Examples

View source: R/FUN-cstat-ver003b.R

Description

Performes the inference for the difference in C between two competing risk prediction models

Usage

1
Inf.Cval.Delta(mydata, covs0, covs1, tau, itr = 1000, seed = NULL)

Arguments

mydata

Input data. The 1st column should be time-to-event, and the 2nd column is event indicator (1=event, 0=censor).

covs0

A matrix that consists of a set of predictors for a base model (Model 0)

covs1

A matrix that consists of a set of predictors for a new model (Model 1)

tau

Truncation time. The resulting C tells how well the given prediction model works in predicting events that occur in the time range from 0 to tau. Note that the survival function for the underlying censoring time distribution needs to be positive at tau.

itr

Iteration of perturbation-resampling.

seed

A seed for generating random numbers for the resampling. The default is NULL.

Value

A 4x3 matrix that consists of point estimates, standard error estiamtes, and lower and upper limits of 0.95 two-sided intervals for C of Model 1, Model 0 and that for the difference of C

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
D=CompCase(pbc[1:200,c(2:4,10:14)]) 
D[,2]=as.numeric(D[,2]==2)


model0<-D[,c(1:2,4:5)] ; 
model1<-D
covs1<-as.matrix(model1[,c(-1,-2)])
covs0<-as.matrix(model0[,c(-1,-2)])

tau=365.25*8

Delta=Inf.Cval.Delta(model0[,1:2], covs0, covs1, tau, itr=200)
round(Delta, digits=3)

survC1 documentation built on Feb. 10, 2021, 5:06 p.m.