Tuesday, February 28, 2006

st: numlist abbreviations interpreted differently in egenmore's eqany S8?

I'm working in Stata 8.

Four ways of generating a numlist of whole positive integers are supposed to be identical, but I'm finding they generate different results with the same dataset in Stata 8.2.

egen nurshealthtech=eqany(jobnum*),v(088 089 095 097 098 099 103/106 134 206/208 235 446 447) egen nurshealthtech2=eqany(jobnum*),v(088 089 095 097 098 099 103:106 134 206:208 235 446 447) egen nurshealthtech3=eqany(jobnum*),v(088 089 095 097 098 099 103 to 106 134 206 to 208 235 446 447) egen nurshealthtech4=eqany(jobnum*),v(088 089 095 097 098 099 103(1)106 134 206(1)208 235 446 447)

. count if nurshealthtech==1 173

. count if nurshealthtech2==1 156

. count if nurshealthtech3==1 156

. count if nurshealthtech4==1 173

Aren't these supposed to be the same?

Yours anxiously, Jen Marino

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


Tag:


Links to this post:

Create a Link



<< Home

This page is powered by Blogger. Isn't yours?