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

From |
"Carlo Lazzaro" <carlo.lazzaro@tin.it> |

To |
<statalist@hsphsun2.harvard.edu> |

Subject |
st: R: command: stpiece |

Date |
Fri, 22 Feb 2008 12:25:44 +0100 |

Dear Chiara, your question might find some helpful answers in Cleves MA, Gould WW, Gutierrez RG. An introduction to survival analysis using Stata. College Station, TX: StataCorp, 2004: 65-66. Id variable is particularly useful whenever you are dealing with multiple records per subject in your dataset. Should your dataset be a single-observation one(I mean, your data set reports the median of unemployment duration measured in months for _n individuals, assuming they are not hired-fired workers; let's say that your data set includes 10 individuals only), you can generate id in the following way (please, see short example below): *************begin example**************** set obs 10 obs was 0, now 10 g id=_n ************end example****************** Sorry I cannot be more helpful. Kind Regards, Carlo -----Messaggio originale----- Da: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] Per conto di Mussida Chiara Inviato: venerd́ 22 febbraio 2008 10.59 A: statalist@hsphsun2.harvard.edu Oggetto: st: command: stpiece Hi guys, I'm trying to sort out a specification issue for stpiece analysis. More precisely I must estimate a piecewise constant hazard model for U duration (survival analysis). This, as you know, means to specify piece in which the dependent variable (for my model it is the unemployment duration, measured in months) is constant. The problem arise since, as stata help suggests: The data must be st. In order to create time pieces, an id variable must be declared with stset. See st and stset. Now: is the id variable an additional variable to ne generated, or it simply refers to my dependent variable and therefore to the precise turning point that I want to specify?? this point for me is the median of the dependent variable distrn, and in a successive estimations there will be more time intervals dictated by the relative frequency of the observations... Thanks for your attention, chiara * * 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/ * * 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: command: stpiece***From:*"Mussida Chiara" <chiara.mussida@unicatt.it>

- Prev by Date:
**st: Heckman probit model with endogenous explanatory variables** - Next by Date:
**RIF: st: command: stpiece** - Previous by thread:
**RIF: st: command: stpiece** - Next by thread:
**st: Heckman probit model with endogenous explanatory variables** - Index(es):

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