use _inrange_
hsgrad = inrange(grade, 9, 12)
-----Original Message-----
From: Jean Roth <[email protected]>
To: [email protected] <[email protected]>
Date: Tuesday, January 28, 2003 3:41 PM
Subject: st: replacing variables
Is it possible to shorten the 'if' statement in the replace below
and still retain the upper and lower bounds?
replace hsgrad = 1 if grade>=9 & grade<=12
Thanks,
Jean Roth
National Bureau of Economic Research
www.nber.org/data
*
* 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/
*
* 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/