Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, is already up and running.

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

st:survival data format

From   getachew Emrie <>
Subject   st:survival data format
Date   Mon, 22 Mar 2010 09:24:53 -0700

I was trying to set  my data in to survival data format. My Interest
is to look the duration of unemployment from CPS data.
The data i have has the following form.

  id   time     employment
  1      1               1
  1      2               1
  1      3               0
  1      4               0
  1      5               1
  2      1               1
  2      2               0
  2      3               1
  2      4               1

(employment=1 if employed and =0 if unemployed). My interest is to
follow the person when he/she enters in to unemployment and look the
time he/ she is going back to employment. Here failure is being
employed (=1). when i try to set it up using stset command with id and
failure=1,data starts with failure and stata ignores all the
observations after first failure. it tells me that most of the data
starts with failure. Is there any way tell stata to ignore failures
before risk of being unemployed  ( for example in the above data  i
want to ignore failures at time 1 and 2 and start at time 3 and then
fail at time 5 for id=1).

Thank you
*   For searches and help try:

© Copyright 1996–2016 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index