For this question, use an R Markdown file. The dataset, "vote.txt," contains the incumbent party's vote percentage of the two-party vote coded as "vote" and average personal income growth in the previous years coded as "growth." The political scientist Douglas Hibbs forecasts elections based solely on economic growth.
(a) Obtain a scatter plot between the two variables (make sure to specify which variable goes on the y-axis), and add the fitted linear regression line.
(b) Fit a simple linear regression in R, predicting elections from the economy. Interpret both estimates (ˆβ0 and ˆβ1) in words.
(c) Predict the incumbent party's vote in the 2008 election and based on that, determine who will win the election between "McCain" and "Obama" (both by hand and in R).
(d) Test whether there is a positive association between the incumbent party's vote share and economic growth.
(e) Give a 95% confidence interval for the mean incumbent party's vote share change as economic growth increases by one unit (percent) (both by hand and in R).
(f) Compute the probability that P(|ˆβ1 - β1| > 1).
vote.txt:
year growth vote inc_party_candidate other_candidate
1952 2.4 44.6 "Stevenson" "Eisenhower"
1956 2.89 57.76 "Eisenhower" "Stevenson"
1960 0.85 49.91 "Nixon" "Kennedy"
1964 4.21 61.34 "Johnson" "Goldwater"
1968 3.02 49.60 "Humphrey" "Nixon"
1972 3.62 61.79 "Nixon" "McGovern"
1976 1.08 48.95 "Ford" "Carter"
1980 -0.39 44.70 "Carter" "Reagan"
1984 3.86 59.17 "Reagan" "Mondale"
1988 2.27 53.94 "Bush, Sr." "Dukakis"
1992 0.38 46.55 "Bush, Sr." "Clinton"
1996 1.04 54.74 "Clinton" "Dole"
2000 2.36 50.27 "Gore" "Bush, Jr."
2004 1.72 51.24 "Bush, Jr." "Kerry"
2008 0.1 46.32 "McCain" "Obama"
2012 0.95 52.00 "Obama" "Romney