In 2017 we have a president who rejects the notion of climate change and global warming, despite a surplus of scientific evidence that indicates the contrary. Considering this current political climate, I thought it would be interesting to investigate the effect of political party on one’s endorsement of global warming. The data that I used was taken from an ABC poll on global warming that was administered in 2008, when the global warming controversy was recieving a lot of publicity due to Al Gore’s “An Inconveinent Truth”.
I hypothesize to find that republican participants are less likely to report belief of global warming than their democratic counterparts.
library(Zelig)
library(ZeligChoice)
library(dplyr)
Attaching package: ‘dplyr’
The following objects are masked from ‘package:stats’:
filter, lag
The following objects are masked from ‘package:base’:
intersect, setdiff, setequal, union
library(tidyr)
Attaching package: ‘tidyr’
The following object is masked from ‘package:texreg’:
extract
library(foreign)
library(visreg)
glowarm <- read.dta("/Users/sophia.halkitis/Desktop/R/Datasets/ICPSR_27322/DS0001/27322-0001-Data.dta", convert.dates = TRUE, convert.factors = TRUE,
missing.type = FALSE,
convert.underscore = FALSE, warn.missing.labels = TRUE)
duplicated levels in factors are deprecatedduplicated levels in factors are deprecatedduplicated levels in factors are deprecatedduplicated levels in factors are deprecated
message = FALSE
gmsub <- subset(glowarm, select=c(CASEID, Q921, Q1, Q10, Q910, Q12, Q3, Q22, Q26, Q901, Q909, Q48, RACENET, RELNET, COLLEDUC)) %>%
rename(
gender = Q921,
serious = Q12,
age = Q910,
rate = Q1,
important = Q10,
reduce = Q26,
trust = Q3,
action = Q22,
party = Q901,
educ = Q909,
source = Q48,
race = RACENET,
college = COLLEDUC,
religion = RELNET)
head(gmsub)
gmsub <- mutate(gmsub, partynew = ifelse(party == "A Democrat",1,
ifelse(party == "A Republican",2,0)))
gmsub <- filter(gmsub, party != "System Missing", party != "Other", party !="DK/No opinion", trust != "System Missing", trust !="DK/No opinion", educ != "System Missing", educ !="DK/No opinion", educ !="8th grade or less", rate != "System Missing", rate !="DK/No opinion")
In the chunk above, I created a subset of the ABC dataset to include variables of interest. I then mutated the variable “political party” into a dichotomous variable to include democrat and republicans. For the sake of the analyses, I did not include people who identified their political affiliation as “independent” or unknown.
library(ggplot2)
ggplot(gmsub, aes(x = trust, fill = gender)) + geom_bar(position = "dodge")
The graph above shows the gender distribution of “trust” in what scientists say about global warming (the dependent variable). It shows a near normal distribution of attitudes about trust in scientists, with females trusting more so in scientist’s conclusions than males.
ggplot(gmsub, aes(x = gender, fill = party)) + geom_bar(position = "dodge")+
facet_wrap("educ")
NA
The faceted graph above shows the distribution of education and party affiliation by gender. It shows a few things:
gmsub <- mutate(gmsub, ratenew = ifelse(rate == "Very poor",1,
ifelse(rate == "Poor",2,
ifelse(rate == "Fair",3,
ifelse(rate == "Good",4,
ifelse(rate == "Excellent",5,0))))))
head(gmsub)
ggplot(gmsub, aes(x = ratenew)) + geom_bar(position = "dodge")+
facet_wrap("party")+
xlab("Ratings of the Environment [Very Poor to Excellent]")
NA
The above chart shows the distribution of participant’s ratings of the environment by party affiliation. It shows that republicans are the most likely (though slight) to rate that the state of the natural environmet is “excellent.” In fact, republicans were equally as likely to rate the environment as “fair” or “good”, while democrats and republicans were most likely to indicate “fair” or “poor”. Democrats were the most liely to indicate that the state of the natural environment is “poor” or “very poor”.
gmsub$trust <- factor(gmsub$trust, ordered = TRUE,
levels = c("Not at all", "A little", "A moderate amount", "A lot", "Completely"))
I chose my dependent variable to be how much participants trust what scientists say about the environment and global warming. “Trust” is an ordinal level variable, with the above answer choices. I then translated the variable “trust” into a factor and labeled it’s levels accordingly in the above chunk.
z.gm <- zelig(trust ~ partynew, model = "ologit",
data = gmsub, cite = F)
summary(z.gm)
Model:
Call:
z5$zelig(formula = trust ~ partynew, data = gmsub)
Coefficients:
Value Std. Error t value
partynew -0.2814 0.07827 -3.596
Intercepts:
Value Std. Error t value
Not at all|A little -3.2553 0.1777 -18.3233
A little|A moderate amount -1.3785 0.1118 -12.3318
A moderate amount|A lot 0.4073 0.1013 4.0192
A lot|Completely 2.6208 0.1645 15.9307
Residual Deviance: 2353.33
AIC: 2363.33
Next step: Use 'setx' method
Upon viewing the summary of the model, we see a strong negative relationship between political party and trust of what scientists say about global warming.
#Tabulation of results
library(texreg)
screenreg(z.gm)
I then ran the simulation, which proved my hypothesis to be correct: republicans are less likely to trust what scientists say about global warming than democrats are.
The probability of trusting what scientists say about global warming decreases as a function of political party, such that republicans are less likely to trust scientists “a lot” or “completely”. Republicans have a higher probability of trusting scientsits “a moderate amount, a little, or not at all” than democrats do.
To assure that this relationship that I observed was true, I estimated the effect of political party on a similiar dependent variable. I ran an additional simulation to see the effect of political party on participant’s ratings on “the condition of the natural enviroment in the world today”.
gmsub$rate <- factor(gmsub$rate, ordered = TRUE,
levels = c("Very poor", "Poor", "Fair", "Good", "Excellent"))
z.rate <- zelig(rate ~ partynew, model = "ologit",
data = gmsub, cite = F)
screenreg(z.rate)
============================
Model 1
----------------------------
partynew 0.41 ***
(0.08)
----------------------------
AIC 2311.40
BIC 2335.28
Log Likelihood -1150.70
Deviance 2301.40
Num. obs. 876
============================
*** p < 0.001, ** p < 0.01, * p < 0.05
summary(z.rate)
Model:
Call:
z5$zelig(formula = rate ~ partynew, data = gmsub)
Coefficients:
Value Std. Error t value
partynew 0.4053 0.07947 5.1
Intercepts:
Value Std. Error t value
Very poor|Poor -2.0787 0.1406 -14.7825
Poor|Fair -0.1152 0.1003 -1.1477
Fair|Good 1.6153 0.1161 13.9067
Good|Excellent 4.5633 0.2849 16.0198
Residual Deviance: 2301.401
AIC: 2311.401
Next step: Use 'setx' method
#Tabulation of the results
screenreg(z.rate)
============================
Model 1
----------------------------
partynew 0.41 ***
(0.08)
----------------------------
AIC 2311.40
BIC 2335.28
Log Likelihood -1150.70
Deviance 2301.40
Num. obs. 876
============================
*** p < 0.001, ** p < 0.01, * p < 0.05
Upon viewing the summary, we see that there is a strong positive relationship between political party and one’s ratings of the environment.
z.rate$setx(partynew = 1)
z.rate$setx1(partynew = 2)
z.rate$sim()
summary(z.rate)
#Graph
plot(z.rate)
#Tablulation of results
library(texreg)
screenreg(list(z.gm, z.rate))
==========================================
Model 1 Model 2
------------------------------------------
partynew -0.28 *** 0.41 ***
(0.08) (0.08)
------------------------------------------
AIC 2363.33 2311.40
BIC 2387.21 2335.28
Log Likelihood -1176.66 -1150.70
Deviance 2353.33 2301.40
Num. obs. 876 876
==========================================
*** p < 0.001, ** p < 0.01, * p < 0.05
Upon running the simulation, we see that republicans are less likely to rate the enviornment as “poor” or “very poor” than their democrat counterparts. This is also in line with my hypothesis, as republicans are more likely to deny climate change, and in turn, would less likely to believe that the natural environment is in poor shape.
(News 2010)
News, ABC. 2010. “ABC News Poll, July 2008.” Inter-university Consortium for Political and Social Research (ICPSR) [distributor]. doi:10.3886/ICPSR27322.v1.