Somebody sent me a dataset with variables like this
one. There were 5 procedures and more than one could
be chosen. Instead of making each a variable, a
single variable was made with commas separating the
procedure number.
procedure | Freq.
------------+-----------
01,02,03 | 11
01,02,03,04 | 1
02 | 6
02,03 | 107
02,03,04 | 14
02,04 | 1
03 | 3
03,04 | 2
04 | 2
05 | 6
I want to make 5 variables that record yes or no for
each procedure. Index() seems to be the way to go but
but I don't see how to use it when there's more than
one instance of the index character. Can somebody
point me in the direction?
Kate
__________________________________________________
Do you Yahoo!?
Yahoo! Platinum - Watch CBS' NCAA March Madness, live on your desktop!
http://platinum.yahoo.com
*
* 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/