Re: st: gamma frailty

 From rgutierrez@stata.com (Roberto G. Gutierrez, StataCorp) To statalist@hsphsun2.harvard.edu Subject Re: st: gamma frailty Date Thu, 24 Jun 2004 11:46:35 -0500

```Rahul Telang <rtelang@andrew.cmu.edu> asks:

> I am running streg with weibull distribution and gamma frailty and want to
> test the impact of a categorical variable (x = 0 or 1). When I plot the
> hazard rate (stcurve) for x = 0 and x = 1, I can see that x = 1 increases
> the hazard but only for low values of duration. After some time both hazards
> converge (x does note matter after few days have elapsed) I am worried that
> proportionality assumption is violated. Some other tests though suggest that
> proportionality assumption is not significantly violated.

> When the run the model without frailty, the two hazards are almost parallel
> for entire duration with (for x=0 and 1). But the fit of the model is much
> worse.

> Should I stick to frailty model and somehow try to correct for
> non-proportionality or not include frailty? Frailty model suggests
> significant heterogeneity.

By default, when you type something such as

. streg x, dist(weib) frailty(gamma)
. stcurve, hazard at1(x=0) at2(x=1)

you get plots of the estimated "population" hazard functions, i.e., the
average hazard function with respect to the frailty distribution.  Even though
you fit a Weibull Proportional Hazards model (the default Weibull model) the
population hazards are not proportional because the proportionality is not
preserved when you integrate out the frailty.

Instead, hazard ratios from such models are interpreted to be conditional on
the frailty.  That is, a hazard ratio for -x- of 0.9 means that "given the
same frailty, the hazard for x=1 is 90% that for x=0".

In order to obtain hazard plots where the frailty is held fixed rather than
integrated out, use the -alpha1- option to -stcurve-.  This sets the frailty
to be fixed at one, and as a result you will see the proportionality in the
resulting plot.

--Bobby
rgutierrez@stata.com
*
*   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/
```