
Code demographic variables in responses
code_geo_vars.RdGiven a dataframe of survey responses, look for standard SurveyMonkey demographic questions and code/recode them into new variables that are more banner-, plot-, and analysis-friendly. Use code_std_demo_vars() to perform all standard demographic recodes, or select the specific function you need. Run std_demo_vars() to return the full index of SurveyMonkey's standard demographic variables.
Value
Survey data frame with new (or updated) columns corresponding to (if discoverable) respondents' geographic location (currently only in the U.S.):
zip: 6-digit ZIP codeurban4: 4-point urban/rural classification for ZIP code based on the USDA's 2010 RUCA (rural-urban commuting area) coding (Metropolitan, Micropolitan, Small town, Rural)zip: 6-digit ZIP codestate_name: state namestate_abb: state abbreviationregion: U.S. Census regiondivision: U.S. Census division