Hi there,
My data is formatted in such a way that multiple choice questions that permitted multiple answers are listed as separate variables (ie. a question about race that allowed "choose all that apply" appears with each option in a different column: race1 is White, race2 is White, race3 is East Asian, etc.) I'm trying to combine the multiple race variables into a single variable. I've already renamed the current variables so that they have the same stubnames with different numeric suffixes.
The code I tried was (where race is the stubname): reshape long race , i(id) But, this resulted in the creation of a single race variable that only includes one option (and all respondents have been assigned that single option). Where did I go wrong? Thanks in advance!
My data is formatted in such a way that multiple choice questions that permitted multiple answers are listed as separate variables (ie. a question about race that allowed "choose all that apply" appears with each option in a different column: race1 is White, race2 is White, race3 is East Asian, etc.) I'm trying to combine the multiple race variables into a single variable. I've already renamed the current variables so that they have the same stubnames with different numeric suffixes.
The code I tried was (where race is the stubname): reshape long race , i(id) But, this resulted in the creation of a single race variable that only includes one option (and all respondents have been assigned that single option). Where did I go wrong? Thanks in advance!
Comment