/* STEP 1. /* Select a couple of countries. We will group East and West Germany together (this data was gathered in 2003). /* This command creates a new variable in the dataset, called "country_new", which is based on the existing variable "COUNTRY". RECODE COUNTRY (2=1) (3=1) (11=2) (16=3) (18=4) (6=5) (ELSE=0) INTO country_new. EXECUTE. /* STEP 2. /* Let's give our new variable a description (label). VARIABLE LABELS country_new 'Selection of countries (recoded)'. EXECUTE. /* STEP 3. /* Give names to those countries. We have numerical codes, but it will be easier for us to know which number represents which country. VALUE LABELS country_new 0 'Other country' 1 'Germany' 2 'Netherlands' 3 'Poland' 4 'Russia' 5 'United States'. EXECUTE. /* STEP 4. /* Let's also define that '0' is a missing value (these are all the other countries). MISSING VALUES country_new (0). EXECUTE. /* STEP 5. /* The following syntax tells SPSS to delete all of the interviews conducted in other countries /* (i.e. if the value for our new variable is zero). FILTER OFF. USE ALL. SELECT IF (country_new > 0). EXECUTE. /* Create dummies per selected country. RECODE country_new (1=1) (ELSE=0) INTO Germany. RECODE country_new (2=1) (ELSE=0) INTO Netherlands. RECODE country_new (3=1) (ELSE=0) INTO Poland. RECODE country_new (4=1) (ELSE=0) INTO Russia. RECODE country_new (5=1) (ELSE=0) INTO United_States. EXECUTE.