Due by 2pm on December 11, 2018.
hw08
repositoryGo here to fork the repo for homework 08.
Joe Biden was the 47th Vice President of the United States. He was the subject of many memes, attracted the attention of Leslie Knope, and experienced a brief surge in attention due to photos from his youth.
biden.csv
contains a selection of variables from the 2008 American National Election Studies survey that allow you to test competing factors that may influence attitudes towards Joe Biden. The variables are coded as follows:
biden
- feeling thermometer ranging from 0-1001female
- 1 if respondent is female, 0 if respondent is maleage
- age of respondent in yearsdem
- 1 if respondent is a Democrat, 0 otherwiserep
- 1 if respondent is a Republican, 0 otherwiseeduc
- number of years of formal education completed by respondent
17
- 17+ years (aka first year of graduate school and up)Estimate the following linear regression:
\[Y = \beta_0 + \beta_{1}X_1\]
where \(Y\) is the Joe Biden feeling thermometer and \(X_1\) is age. Report the parameters and standard errors.
biden
does age
alone explain? Is this a good or bad model?biden
associated with an age
of 45? What are the associated 95% confidence intervals?It is unlikely age
alone shapes attitudes towards Joe Biden. Estimate the following linear regression:
\[Y = \beta_0 + \beta_{1}X_1 + \beta_{2}X_2 + \beta_{3}X_3\]
where \(Y\) is the Joe Biden feeling thermometer, \(X_1\) is age, \(X_2\) is gender, and \(X_3\) is education. Report the parameters and standard errors.
female
suggest?biden
does age, gender, and education explain? Is this a better or worse model than the age-only model?Estimate the following linear regression:
\[Y = \beta_0 + \beta_{1}X_1 + \beta_{2}X_2 + \beta_{3}X_3 + \beta_{4}X_4 + \beta_{5}X_5\]
where \(Y\) is the Joe Biden feeling thermometer, \(X_1\) is age, \(X_2\) is gender, \(X_3\) is education, \(X_4\) is Democrat, and \(X_5\) is Republican.2 Report the parameters and standard errors.
biden
does age, gender, education, and party identification explain? Is this a better or worse model than the age + gender + education model?Estimate the following linear regression model of attitudes towards Joseph Biden:
\[Y = \beta_0 + \beta_{1}X_1 + \beta_{2}X_2 + \beta_{3}X_3\]
where \(Y\) is the Joe Biden feeling thermometer, \(X_1\) is age, \(X_2\) is gender, and \(X_3\) is education. Report the parameters and standard errors.
For this section, be sure to
na.omit()
the data frame (listwise deletion) before estimating the regression model. Otherwise you will get a plethora of errors for the diagnostic tests.
Estimate the following linear regression model:
\[Y = \beta_0 + \beta_{1}X_1 + \beta_{2}X_2 + \beta_{3}X_1 X_2\]
where \(Y\) is the Joe Biden feeling thermometer, \(X_1\) is age, and \(X_2\) is education. Report the parameters and standard errors.
Again, employ listwise deletion in this section prior to estimating the regression model.
Your assignment should be submitted as an R Markdown document rendered as an HTML/PDF document. Don’t know what an R Markdown document is? Read this! Or this! I have included starter files for you to modify to complete the assignment, so you are not beginning completely from scratch.
Follow instructions on homework workflow. As part of the pull request, you’re encouraged to reflect on what was hard/easy, problems you solved, helpful tutorials you read, etc.
Feeling thermometers are a common metric in survey research used to gauge attitudes or feelings of warmth towards individuals and institutions. They range from 0-100, with 0 indicating extreme coldness and 100 indicating extreme warmth.↩
Independents must be left out to serve as the baseline category, otherwise we would encounter perfect multicollinearity.↩
This work is licensed under the CC BY-NC 4.0 Creative Commons License.