Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Muliple condition statement


From   Hannah Moore <hannahm@ichr.uwa.edu.au>
To   statalist@hsphsun2.harvard.edu
Subject   st: Muliple condition statement
Date   Wed, 11 Aug 2004 16:11:10 +0800

Is it possible to have a multiple condition statement?

I would like to generate a new variable:

entry = entrydate if var1==0, date1 if var1==1, date2 if var2==2.........., date9 if var9==9

Can someone please tell me whether this is possible in 1 step, and what the correct syntax would be?

Thanks

Hannah

*
* 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