Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


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

RE: st: Dummy variable transformation replacing missing data


From   Nick Cox <[email protected]>
To   "'[email protected]'" <[email protected]>
Subject   RE: st: Dummy variable transformation replacing missing data
Date   Mon, 11 Jun 2012 16:10:10 +0100

That's a very good FAQ but it's not quite what Joe is asking for. 

Joe wants something like this: 

egen x1 = max(x), by(id) 

except to that to be safe this should only be used if the result of 

egen xcount = count(x), by(id) 

is at most one. 

Nick 
[email protected] 

Ronnie Babigumira

This might be helpful

http://www.stata.com/support/faqs/data/missing.html 

On Monday, June 11, 2012 at 2:54 PM, Joe Dreyfus wrote:

 
> I have the following data.
> 
<snip>  
> 
> 
> The time period where the indicator is on is not relevant. I just need to know how to transform the variable so that if it is swtiched on in one time period it is transformed to be switched on for all time periods. 
> 

*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index