Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Survival analysis: Time interactions for hazards that cross multipletimes


From   Maria Khan <[email protected]>
To   [email protected]
Subject   st: Survival analysis: Time interactions for hazards that cross multipletimes
Date   Tue, 22 Feb 2005 15:28:47 -0500

Hi,

In survival analysis we may need to create an interaction with continuous time or categorical time. If we see a continual increase in the HR for men versus the referent women, it would suffice to create an interaction with continuous time with our gender variable ("gender"). To create an interaction with continuous time, the code would be:
stcox gender, efron nohr tvc(gender)

Say we must create an interaction with categorical time in the case that there is a non-monotonic departure from proportionality of the hazards of the two strata of the variable of interest. Say before 96 months of follow-up, we observe one HR for males v females, and after time 96 months, we observe a drastically different HR for males v females. The STATA code would then be: stcox gender, tvc(gender) texp(survtime>96) nohr

But say the HR changes three times. For example, at 96 months and again at 120months. There would be three different HRs for the effect of gender, depending on the time period.

Does anyone know code for this??

Thanks-
Maria Khan

*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/




© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index