************************************************************************** ************************************************************************** * Monkey Cage submission * Negative Ethnocentrism * L.J Zigerell and Arafat Kabir * Code by L.J Zigerell * ANES 2012 Time Series Study * http://www.electionstudies.org/studypages/anes_timeseries_2012/anes_timeseries_2012.htm ************************************************************************** ************************************************************************** set mem 500m use "anes_timeseries_2012_Stata12.dta", clear set more off tab wave_completions keep if wave_completions == 1 // keep only respondents who were in pre-election and post-election survey tab wave_completions ******************************************************************************************************************************* *** Code white respondents ******************************************************************************************************************************* tab dem_raceeth gen white = dem_raceeth recode white (-9/-1 = 0) (2 3 4 = 0) tab dem_raceeth white keep if white==1 ******************************************************************************************************************************* *** White ethnocentrism measure ******************************************************************************************************************************* tab1 ftcasi_white ftcasi_black ftcasi_hisp ftcasi_asian sum ftcasi_white ftcasi_black ftcasi_hisp ftcasi_asian // Remove non-respondents to the feeling thermometer items drop if ftcasi_white<0 | ftcasi_black<0 | ftcasi_hisp<0 | ftcasi_asian<0 sum ftcasi_white ftcasi_black ftcasi_hisp ftcasi_asian // Remove non-respondents to the feeling thermometer items gen ftw = ftcasi_white gen ftb = ftcasi_black gen fth = ftcasi_hisp gen fta = ftcasi_asian recode ftw ftb fth fta (-10/-1=.) tab1 ftw ftb fth fta sum ftw ftb fth fta gen ecw = ftw - ((ftb+fth+fta)/3) sum ecw if white==1 sum ecw if ecw<0 & ecw!=. & white==1 sum ecw if ecw==0 & ecw!=. & white==1 sum ecw if ecw>0 & ecw!=. & white==1 di 267/3226 // 8.3% di 1199/3226 // 37.2% di 1760/3226 // 54.5% gen ethnoWneg = ecw replace ethnoWneg = 1 if ecw<0 & ecw!=. replace ethnoWneg = 0 if ecw>=0 & ecw!=. sum ethnoWneg if white==1 gen ethnoWnon = ecw replace ethnoWnon = 1 if ecw==0 & ecw!=. replace ethnoWnon = 0 if ecw<0 & ecw!=. replace ethnoWnon = 0 if ecw>0 & ecw!=. sum ethnoWnon if white==1 gen ethnoWpos = ecw replace ethnoWpos = 1 if ecw>0 & ecw!=. replace ethnoWpos = 0 if ecw<=0 & ecw!=. sum ethnoWpos if white==1 ******************************************************************************************************************************* *** Outcome variables ******************************************************************************************************************************* * Immigration levels tab immigpo_level gen moreImmig01 = immigpo_level recode moreImmig01 (-10/-1=.) (1 2=1) (3 4 5=0) tab immigpo_level moreImmig01 * Support affirmative action in universities tab aa_uni_x gen aactionUni01favor = aa_uni_x recode aactionUni01favor (-10/-1=.) (1/3=1) (4/7=0) tab aa_uni_x aactionUni01favor ******************************************************************************************************************************* *** Weighted statistics ******************************************************************************************************************************* svyset [pweight=weight_full], strata(strata_full) psu(psu_full) svy, subpop(white): tab moreImmig01 if ethnoWneg==1 svy, subpop(white): tab moreImmig01 if ethnoWnon==1 svy, subpop(white): tab moreImmig01 if ethnoWpos==1 svy, subpop(white): tab aactionUni01 if ethnoWneg==1 svy, subpop(white): tab aactionUni01 if ethnoWnon==1 svy, subpop(white): tab aactionUni01 if ethnoWpos==1 ******************************************************************************************************************************* *** Unweighted statistics ******************************************************************************************************************************* ci moreImmig01 if white==1 & ethnoWneg==1 ci moreImmig01 if white==1 & ethnoWnon==1 ci moreImmig01 if white==1 & ethnoWpos==1 ci aactionUni01 if white==1 & ethnoWneg==1 ci aactionUni01 if white==1 & ethnoWnon==1 ci aactionUni01 if white==1 & ethnoWpos==1