Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Creating time-dependent covariates to replicate the tvc option for stcrreg

From (Roberto G. Gutierrez, StataCorp)
Subject   Re: st: Creating time-dependent covariates to replicate the tvc option for stcrreg
Date   Mon, 05 Apr 2010 12:36:17 -0500

Travis Coan <> asks:

> I am trying to use interaction terms that I created manually to replicate
> the results provided by the tvc option after Stata's stcrreg command.
> Needless to say, I am not having much success.

> I have tried to use the suggestions provided in Stata's "tvc note" help file
> (help tvc_note) for stcox. For example, with the Hypoxia Study data used in
> the Stata manual (Example 1, pg. 200):

> stset dftime, failure(failtype == 1) id(stnum) 
> stsplit, at(failures)
> gen ifptime = ifp*_t
> stcrreg ifp tumsize pelnode ifptime, compete(failtype == 2)

> These results are different from those produced by Stata's tvc option:

> stcrreg ifp tumsize pelnode, compete(failtype == 2) tvc(ifp)

> If anyone has any advice on this issue (or could point me to resources on
> the issue), I would greatly appreciate it. Thanks so much for your
> consideration.

Unlike with -stcox-, using the -tvc()- option with -stcrreg- is not equivalent
to splitting observations and generating the time interactions manually.  That
is because in competing-risks regression subjects remain in risk-pool
calculations past the time when they fail, if they fail due to competing
reasons.  When this happens, it raises the question of what to do with the
values of the covariates for that subject past their failure time.

Suppose the event of interest is lung cancer, a heart attack is a competing
event, and we are measuring (among other things) BMI for each subject.  If we
use the -tvc(bmi)- option to -stcrreg-, then Stata can extrapolate values of
-bmi- past the time of the heart attack because it has a mathematical
expression for doing so.  When you split observations, however, Stata has no
recourse but to keep -bmi- fixed at its most recent observed value, that is,
its value when the subject had their heart attack.  You will get different

Because -tvc()- extrapolates covariates past failure, you might be skeptical
toward the results because this is unlikely to reflect any real-data
situation.  However, if you instead interpret what you get out of -tvc()- as
time-varying _coefficients_, what you get out of -tvc()- is a test of the
proportional subhazards assumption; see pp. 214-215 of [ST] stcrreg for more

*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index