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]
st: Missing value= Help with gen command.
From
vikramfinavker <[email protected]>
To
[email protected]
Subject
st: Missing value= Help with gen command.
Date
Thu, 5 May 2011 05:38:45 -0700 (PDT)
HI all,
I am trying to generate new variable which is sum of A and B. i used:
gen dumab=0
replace dumab=1 if A+B>0
however my problem is that where A has value and B has missing value (.) it
gives me answer (.) but instead i want 1.
Could any one please help me with this.
Thanks a lot.
--
View this message in context: http://statalist.1588530.n2.nabble.com/Missing-value-Help-with-gen-command-tp6334141p6334141.html
Sent from the Statalist mailing list archive at Nabble.com.
*
* 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/