Linear Regression

Download the file mediasexism.csv, load the data into R, and view the data to familiarize yourself with the variables:
Country is the observation unit in the file
Year is the year of the election
Expert is the total number of news stories that portray women candidates as political experts
Candidates is the total number women candidates that ran for the election
Seats is the total number of seats won by women in the corresponding country’s lower chamber
Create a scatterplot showing the relationship between media sexism, as represented the number of stories that portray women candidates as experts, and political ambition (measured by either candidates or seats). Hint, you should have two scatterplots because there are two response variables for political ambition.
Change the point type from the default, give the figure a title, and label the axes appropriately. You will come back to this figure after completing the linear regression.
Q1: What type of relationship, if any, is apparent between media sexism and political ambition?
Form Hypotheses
In this study, we want to know if there is any relationship media sexism and women’s political ambition.
We will be performing two linear regressions: one for each response variable.
Q2: What are the null and alternative hypotheses of your linear regressions?
Perform Linear Regressions
Individually, perform the linear regression for media sexism and political ambition (as represented by the number of candidates) using the lm() and summary() functions in R.
As a group, identify the parameters of your linear regression.
Q3: What is the equation of your linear regression for media sexism and candidates?
Now, perform a linear regression for media sexism and political ambition (as represented by the number of seats) using the lm() and summary() functions in R.
Q4: What is the equation of the linear regression for media sexism and seats?
Q5: Include your scatterplots, with your regression line.

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *