R studio
Problem Set 9
This problem set is due on Friday November 20th end of day. This problem set is worth a total of 110 points (so 10 points extra credit).
1 Exercise 1: 2016 Polls (50%)
The following questions contain data from polls in 5 states conducted right before the 2016 U.S. Presidential election. For each poll, I include the sample size and the sample proportion that said they intended to vote for Trump. In all these questions I’m asking you to test some null hypotheses. To do this, first calculate the z-score and then compare the z-score to the critical values.
a. A Florida poll from Quinnipiac University of 884 likely voters conducted between November 3 and November 6 of 2016 found that 45% of those polled intended to vote for Donald Trump.
i. (5pts) Test the null hypothesis that Trump would obtain 49.02% (what he actually obtained in 2016), based on the results of this poll. Would you accept or reject this null hypothesis at the 5% significance level? Calculate the z-score to make this determination.
ii. (5pts) Test the null hypothesis that Trump would obtain 42% of the FL vote, using a significance level of 5%.
b. A Virginia poll from Public Policy Polling of 1238 likely voters conducted between November 3 and November 4 of 2016 found that 43% of those polled intended to vote for Donald Trump.
i. (5pts) Test the null hypothesis that Trump would obtain 50% of the VA vote at the 5% significance level.
ii. (5pts) Test the null hypothesis that Trump would obtain 44.4% (the actual result) of the VA vote at the 5% significance level.
c. A Pennsylvania poll from YouGov of 931 likely voters conducted between November 3 and November 5 of 2016 found that 43% of those polled intended to vote for Donald Trump.
i. (5pts) Test the null hypothesis that Trump would obtain 40% of the PA vote using the 5% significance level.
ii. (5pts) Test the null hypothesis that Trump would obtain 48.18% of the PA vote using the 5% significance level.
d. A North Carolina poll from Sienna College of 800 likely voters conducted between November 4 and November 6 of 2016 found that 44% of those polled intended to vote for Donald Trump.
i. (5pts) Test the null hypothesis that Trump would obtain 49.83% of the NC vote using a 5% significance level.
ii. (5pts) Test the null hypothesis that Trump would obtain 42% of the NC vote at the 5% significance level.
e. An Iowa poll from Selzer & Company of 800 likely voters conducted between November 1 and November 4 of 2016 found that 46% of those polled intended to vote for Donald Trump.
i. (5pts) Test the null hypothesis that Trump would obtain 51.15% of the IA vote using a 5% significance level.
ii. (5pts) Test the null hypothesis that Trump would obtain 48% of the IA vote using a 5% significance level.
2 Exercise 2: Indiscriminate Violence and Insurgency, Revisited (30%)
In this exercise, you will analyze the relationship between indiscriminate violence and insurgent attacks using data about Russian artillery fire in Chechnya from 2000 to 2005, that you already analyzed in Problem Set 3.
You don’t really need to do anything new in R for this exercise. Instead, you can rely on the results you obtained in PS8 to do the hypothesis tests.
This exercise is based on Lyall, J. 2009. “Does Indiscriminate Violence Incite Insurgent Attacks: Evidence from Chech- nya,” Journal of Conflict Resolution 53(3): 331 – 362.
Some believe that indiscriminate violence increases insurgent attacks by creating more cooperative relationships between citizens and insurgents. Others believe that indiscriminate violence can be effective in suppressing insurgent activities.
In this exercise you will try to answer this question using a dataset constructed around 159 events in which Russian artillery shelled a village. For each such event the data records the village where the shelling took place and whether it was in Grozny (the Chechen capital), how many people were killed, and the number of insurgent attacks 90 days before and 90 days after the date of the event. Then, the authors of the original study added information for a set of demographically and geographically similar villages that were not shelled by Russian artillery fire around the same time periods. The goal of adding these villages is to have a control group.
1
Name Description village Name of Village groznyy Variable indicating whether a village is in Grozny (1) or not (0) fire Whether Russians shelled a village with artillery fire (1) or not (0) deaths Number of individuals killed during Russian artillery fire or NA if not fired on preattack The number of insurgent attacks in the 90 days before being fired on postattack The number of insurgent attacks in the 90 days after being fired on
The names and descriptions of the variables in the data file chechen.csv are: Note that the same village may appear in the dataset several times as shelled and/or not shelled because Russian attacks
occurred at different times and locations. Also, note that, at a first glance, the variables preattack and postattack do not seem to make much sense for villages
that were not shelled. However, as previously mentioned, these villages were included as a control group in the same way as we used Ohio as a control for the change in the voter ID law in Indiana. The difference with the example we used in class is that villages were attacked at different points in time, whereas all Indiana counties got the voter ID law at the same time (as it is state law). Therefore, researchers had to find a control village for each time a village was shelled. For these control villages, the preattack and postattack variables are defined around the time of the attack in some other, shelled village. Despite each non-shelled village being added as a control for a shelled village, you will treat all non-shelled villages as controls for shelled villages. In this sense, you will treat villages like we treated counties in Ohio and Indiana in class.
Thus, the outcome here is the number of insurgent attacks, and the treatment variable is whether the Russians shelled the village or not. The treatment variable for the “after” period is measured in postattack and for the “before” period in preattack. The treatment variable is measured in fire and it takes the value 1 if in the treatment group and 0 if in the control group. Notice that, unlike in the Voter ID Law case we studied in the video lecture, the treatment variable is numeric here (rather than text). Thus, when subsetting we don’t need quotation marks as we needed in that case. So to subset to those observations for which variable fire in the dataset chechen are equal to 1 (the treatment group), we’d use [chechen$fire == 1]
a. (10pts) Relying on your results for the Difference-in-Means (DiM) estimator, test the null hypothesis that the Population Average Treatment Effect (PATE) is equal to zero. Do you find that indiscriminately firing upon Chechen villages is statistically significant?
b. (10pts) Relying on your results for the Before and After (BA) estimator, test the null hypothesis that the Population Average Treatment Effect (PATE) is equal to zero. Do you find that indiscriminately firing upon Chechen villages is statistically significant?
c. (10pts) Relying on your results for the Difference-in-Differences (DiD) estimator, test the null hypothesis that the Population Average Treatment Effect (PATE) is equal to zero. Do you find that indiscriminately firing upon Chechen villages is statistically significant?
3 Exercise 3: Does the Minimum Wage Reduce the Proportion of Full Time Employees? (30%)
While researchers typically rely on a 5% significance level, other commonly used levels are 1% and 10%. The critical values for these levels are:
Significance Level Critical Values 1% ±1.64 5% ±1.96 10% ±2.58
In the exercise we’ve discussed before about the minimum wage increase in New Jersey, we obtained the following results:
Estimate Standard Deviation of the Estimator DiM 0.048 0.034 BA 0.024 0.018 DiD 0.062 0.046
a. (10pts) Using the results of the DiM estimator, test the null hypothesis that the Population Average Treatment Effect (PATE) is equal to zero, using three different tests: 1%, 5%, and 10% significance level. In which cases do you accept or reject the null hypothesis?
2
b. (10pts) Using the results of the Before and After estimator, test the null hypothesis that the Population Average Treatment Effect (PATE) is equal to zero, using three different tests: 1%, 5%, and 10% significance level. In which cases do you accept or reject the null hypothesis?
c. (10pts) Using the results of the Before and After estimator, test the null hypothesis that the Population Average Treatment Effect (PATE) is equal to -0.10, using three different tests: 1%, 5%, and 10% significance level. In which cases do you accept or reject the null hypothesis?
3