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 at the end of May, and its replacement, statalist.org is already up and running.


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

RE: st: Coding for multiple visits data


From   Tasha Amin <tamin_wh@hotmail.com>
To   Stata list <statalist@hsphsun2.harvard.edu>
Subject   RE: st: Coding for multiple visits data
Date   Fri, 8 Apr 2011 16:52:54 -0400


Re: Shouldnt it just be replace case=case-RNA if case==1----Unfortunately, this doesn't work as this would change case to 1 at visit 5, not visit 6, ie at first RNA=0, NOT second, successive RNA=0.
 
Thanks for the suggestion though. Anyone else?
 

>
> On Fri, Apr 8, 2011 at 4:34 PM, Tasha Amin
> > wrote:
>
>
> My data has multiple visits and is coded in the following way, where a
> person appears as a case=1 from visit 1.....(see first set of code),
> even though ID 1 should be case=1 from visit 6, after 2 successive 0's
> in RNA, ie SHOULD look like second set of code. How do I get case to
> accurately change at the right visit? Thanks!
>
> Looks like:
> ID visit RNA case
> 1 1 1 1
> 1 3 1 1
> 1 5 0 1
> 1 6 0 1
> 1 7 0 1
> 2 1 1 0
> 2 2 1 0
> 2 3 1 0
> 2 4 1 0
>
> Want it to look like:
> ID visit RNA case
> 1 1 1 0
> 1 3 1 0
> 1 5 0 1
> 1 6 0 1
> 1 7 0 1
> 2 1 1 0
> 2 2 1 0
> 2 3 1 0
> 2 4 1 0
> *
> * For searches and help try:
> * http://www.stata.com/help.cgi?search
> * http://www.stata.com/support/statalist/faq
> * http://www.ats.ucla.edu/stat/stata/
> 		 	   		  
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   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   |   Site index