[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

From |
Enzo Coviello <enzo.coviello@tin.it> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
Re: st: standard error of the hazard (not the cumulative hazard) at each time t? |

Date |
Sat, 24 Apr 2004 20:44:55 +0200 |

At 13.40 24/04/04 -0400, you wrote:

Can anyone tell me how to have Stata produce the standard error of the hazard (not the cumulative hazard) at each time t? For instance, the two commands, sts generate cum_haz = na, by(com_lang) sts generate cum_haz_se = se(na), by(com_lang) will do what I want for the cumulative hazard. In addition, sts generate haz = h, by(com_lang) will generate the hazard function.

Be careful.

Using:

. sts gen newvarname = h

you estimate the hazard component, not the hazard function (see Survival Manual)

You can easily achieve a kernel smoothed estimate of the hazard function, its standard error and log transformed confidence interval using stkerhaz. For more detail you can type:

.findit stkerhaz

or

. ssc desc stkerhaz

After downloading, you can achieve what you want typing:

. stkerhaz, basecha(cum_haz) ci out(myhazard_estimate,replace) strata(com_lang)

.stkerhaz will produce a Stata7 graph with hazard and confidence interval and a file (in the current directory if not otherwise specified) where the estimates are saved. Then

.use myhazard_estimate, clear

Now you can give a glance at your estimates or achieve a nicer Stata8 graph.

Note that using option np(#) the hazard and its confidence interval can be estimated at more points as you need.

Hope this help

Enzo

Enzo Coviello

Dipartimento di Prevenzione ASL BA/1

via L. Barbera 27

70055 MINERVINO MURGE (BA)

Italy

tel - fax +390883691053

(home) +390883695055

*

* 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/

**References**:**st: standard error of the hazard (not the cumulative hazard) at each time t?***From:*Tom Prusa <prusa@economics.rutgers.edu>

- Prev by Date:
**st: standard error of the hazard (not the cumulative hazard) at each time t?** - Next by Date:
**st: combining forest plots** - Previous by thread:
**st: standard error of the hazard (not the cumulative hazard) at each time t?** - Next by thread:
**st: combining forest plots** - Index(es):

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