Hello, all.
I have data with a household identifier (serial) and a person locator within each household (pernum).
Is there any way to maintain a sort order of PERNUM within SERIAL, i.e., the results of a command like -sort serial pernum- for a -bysort- that is sorted on a within-household indicator variable, i.e. -bysort serial (indicatorvar): several expressions to condition the value of a PERNUM-level variable-
My question may seem odd, but the person's location in the household is an important criterion for determining the indicator variable's value. Unfortunately, the value of the indicator variable may be the same for more than one person in the household, so I can't use -bysort serial pernum (indicatorvar): stuff-
As always, any help is greatly appreciated.
Best,
Deborah Garvey
******************************
Deborah Garvey, Ph.D.
Department of Economics
Kenna Hall
Santa Clara University
Santa Clara, CA 95053
408/554-5580
408/554-2331 (FAX)
[email protected]
http://lsb.scu.edu/~dgarvey
**********************************
This message scanned for viruses and SPAM at SCU (MGW2)
*
* 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/