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: Get back to original sample data
From
Nick Cox <[email protected]>
To
[email protected]
Subject
Re: st: Get back to original sample data
Date
Sun, 5 Jun 2011 10:20:17 +0100
gen is4 = substr(string(sich), 1, 1) == "4"
... if is4
Nick
On Sun, Jun 5, 2011 at 9:32 AM, Achmed Aldai <[email protected]> wrote:
> Hi
>
> I am currently working on a do file where I am eliminating firms of different industries. Here is an extract
>
> gvkey sich
> 1001 1120
> 1001 1120
> 1001 1120
> 1001 1120
> 1001 1120
> 1200 2310
> 1200 2310
> 1200 2310
> 1200 2310
> 3201 4320
> 3201 4320
> 3210 4335
> 3210 4335
>
> If I drop e.g. all firms with a beginning sich of 4: After this analysis I want to have all the firms in my sample again. So how can I come back to the complete sample again to do another analysis.
> I want to have all this in the same do file.
*
* 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/