Learn R Programming

tteICE (version 1.1.2)

bshaz.tteICE: Baseline hazards of 'tteICE' objects

Description

This function extracts the baseline cumulative hazards in the survival models

Usage

# S3 method for tteICE
bshaz(x)

Value

A data frame of baseline cumulative hazards in the working Kaplan-Meier or Cox models, stratified by treatment groups. The first column is time, the following columns are baseline cumulative hazards.

Arguments

x

A fitted object returned by the function tteICE, surv.tteICE, or scr.tteICE.

Examples

Run this code
## load data
data(bmt)
bmt = transform(bmt, d4=d2+d3)
A = as.numeric(bmt$group>1)
X = as.matrix(bmt[,c('z1','z3','z5')])
bmt$A = A

fit = tteICE(Surv(t2, d4, type = "mstate")~A|z1+z3+z5,
 data=bmt, strategy="whileon", method='eff')
bshaz(fit)

Run the code above in your browser using DataLab