Statalist


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

st: Fwd: FW: duration of mulitple episodes in panel data


From   Maarten buis <maartenbuis@yahoo.co.uk>
To   stata list <statalist@hsphsun2.harvard.edu>
Subject   st: Fwd: FW: duration of mulitple episodes in panel data
Date   Fri, 20 Jun 2008 15:56:54 +0100 (BST)

--- "Dherani, Mukesh" wrote:
> I have been trying to send following message to the stata group but
> for some reasons it has not appeared. I am forwarding you this for
> some help.

The reason that the post did not reach Statalist was that it wasn't
formatted in plain text. For more on this see the statalist FAQ. Here
is the message in plain text:


> Dear Statalisters, 
> 
> In my dataset there may be multiples episodes outcome for each child.
>  I want to assess the duration of each episode assuming that episode
> ended on a visit before a disease free visit.  For example: for child
> 1 first episode started on 12th Jan and ended on 15th as next visit
> on 22nd was disease free. Hence duration of that particular episode
> was 4 days. 
> 
> First three columns are what I have got in my dataset, I need to
> create last three columns. 
> 
> I tried various ‘egen’  functions like ‘group’ or ‘count’ but to no
> avail.  I tried searching FAQ on stata.com but so far no success. Can
> someone help me please.
> 
ID date episode episode number visits episode lasted Duration of
episode
 
1 05/01/2006 0
    
1 12/01/2006 1 1 1
  
1 15/01/2006 1 1 2 4
 
1 22/01/2006 0    

1 30/01/2006 1 2 1
  
1 05/02/2006 1 2 2 7
 
1 10/02/2006 1 2 3 12
 
1 15/02/2006 0
    
2 03/01/2006 0
    
2 10/01/2006 0
    
2 15/01/2006 0
    
2 18/01/2006 1 1 1
  
2 25/01/2006 0
    
2 01/02/2006 0
    
2 08/02/2006 1 2 1
  
2 15/02/2006 1 2 2 8
 
2 25/02/2006 1 2 3 18

-----------------------------------------
Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands

visiting address:
Buitenveldertselaan 3 (Metropolitan), room Z434

+31 20 5986715

http://home.fsw.vu.nl/m.buis/
-----------------------------------------


      __________________________________________________________
Sent from Yahoo! Mail.
A Smarter Email http://uk.docs.yahoo.com/nowyoucan.html
*
*   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/



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