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

st: pgmhaz/hshaz output, why does it look like this?

From   "Stephen P. Jenkins" <>
To   <>
Subject   st: pgmhaz/hshaz output, why does it look like this?
Date   Fri, 20 Feb 2009 10:00:52 -0000


Date: Thu, 19 Feb 2009 10:30:50 +0100
From: Hilde Karlsen <>
Subject: st: pgmhaz/hshaz output, why does it look like this?

Dear statalisters,

I am having trouble understanding why the result of my pgmhaz-command 
ends up like shown in the output below. (Why are there "missing"
on several of the estimates?)

Does this imply I should not use pgmhaz for my discrete time hazard 
analysis? I've tried hshaz, but it yielded the same result. Moreover, 
constructing the baseline hazard in a different manner (for example 
log(time), or creating finer time units with dummy variables) also
not solve this problem. I am trying to find out wether there is 
significant heterogeneity in the data, and the first analysis (nocons)

suggested statistically significant frailty. Should I rather be using
different command/program?

Here is my syntax and output; I hope it is readable.

. pgmhaz  year1_4 year5_7 year8_10 male, i(LPNR) s(year) d(movedout)

PGM hazard model with Gamma heterogeneity	

Number of obs	=   16181
Model chi2(3)	=       .
Prob > chi2	=       .
Log Likelihood =  -1003.6567957

movedout    Coef.      Std. Err.      z	  P>z
year1_4   -.5213477   .1809304    -2.88	  0.004
year5_7   -.0568201          .        .	    .
year8_10   .1837397    .218296     0.84	  0.400
_cons   -4.199123     .1344249   -31.24	  0.000
_cons   -14.54299          .        .	.
Gamma variance, exp(ln_varg) = 4.831e-07; Std.	Err. = 0; z = .
- --------


If you wish to include dummy variables for all of the year* duration
intervals, then you need to exclude the constant term from the
regressor list. (Alternatively, drop one of the year* variables.) In
short, you have a perfect collinearity issue with your syntax. The
same applies to -hshaz- syntax use.  I am sceptical about your claim
that the same problem arose when you used log(duration) instead of the
year* dummies.  But then, contrary to Statalist FAQ recommendations,
you haven't showed exactly what you typed in that case.

An estimate of -14.5 for log(gamma variance) implies an estimate of
the gamma variance of near-enough zero. This is probably telling you
that frailty (unobserved heterogeneity) is hard to find with your
data.  You can investigate this further by tracing the path of
estimates at each step, and experimenting with different starting
values for the log(gamma variance). Fix the collinearity issue first

I strongly recommend reading the appropriate Lesson at my website (and
the help files) for discussion of these issues, with illustrations.
URL is in my signature below.

Finally, you should update and use -pgmhaz8- rather than -pgmhaz-
(assuming you have version 8 or higher)

Professor Stephen P. Jenkins <>
Director, Institute for Social and Economic Research
University of Essex, Colchester CO4 3SQ, U.K.
Tel: +44 1206 873374.  Fax: +44 1206 873151.  
Survival Analysis using Stata:
Downloadable papers and software:

Learn about the UK's new household panel survey, "Understanding

*   For searches and help try:

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