I created a survey in which the respondents were asked who, in their opinion, is responsible for the situation on the polish-belarusian border. Multiple responses were possible. I would like to summarize everything in one table.
The new variable should be named "responsible" with the categories: 1 "Belarus" 2 "Polen" 3 "Deutschland" 4 "EU" 5 "Nobody" 6 "No Answer"
My dataset looks like this:
How do I create this new variable with 6 categories?
Thanks in adavance!
The new variable should be named "responsible" with the categories: 1 "Belarus" 2 "Polen" 3 "Deutschland" 4 "EU" 5 "Nobody" 6 "No Answer"
My dataset looks like this:
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(responsible_belarus responsible_polen responsible_deutschland responsible_EU responsible_nobody responsible_noanswer) 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 1 1 1 1 0 0 1 0 0 1 0 0 1 0 0 0 0 0 1 1 0 0 0 0 1 0 0 0 0 0 1 0 0 1 0 0 1 1 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 1 1 1 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0 0 1 0 0 1 1 1 1 0 0 1 0 0 0 0 0 1 1 1 1 0 0 1 0 0 1 0 0 0 0 0 0 0 1 1 1 1 1 0 0 1 1 1 1 0 0 0 0 0 0 1 0 1 0 0 0 0 0 1 0 0 1 0 0 1 1 1 1 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 1 0 1 0 0 0 0 0 1 1 0 1 0 0 1 1 1 1 0 0 1 0 0 1 0 0 1 0 0 0 1 0 1 0 0 0 0 0 1 1 1 1 0 0 0 0 0 1 0 0 1 1 1 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 1 0 1 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 1 1 0 1 0 0 0 0 0 1 0 0 1 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