stcrprep
stcrprep prepares data for estimating and modelling cause-specific cumulative incidence functions using time-dependent weights. Once the data has been prepared and the weights incorporated using stset it is possible to obtain a graph of the non-parametric estimates of the cause-specific cumulative incidence function using sts graph. In addition a model that estimates subhazard ratios (equivalent to the Fine and Gray model) can be fitted using stcox. It is also possible to fit parametric models to directly estimate the cause-specific CIF (my main reason for developing the command), for example using stpm3.
More details can be found in the Stata Journal article
I should point out that I am less keen on modelling the subhazard than when I wrote this command. Generally, I prefer to use fit cause-specific hazard models for each cause and then combine these to estimate the cause-sepcific CIFs.
Below are some simple examples of using stcrprep.
Examples
Non and semi parametric methods
Parametric models
- Using
stpm3to model the cause-specific CIF - Alternative link functions.