1. (0 points) Using the read.csv() function, read in surveyA.csv and electoral_votes.csv
Part 1
2. (5 points) Calculate mean trump vote for each state using survey A.
3. (10 points) Calculate the standard errors for the mean trump vote by state. Why is the standard error so much larger (in some cases, nearly 8x as big) for some states than other states?
4. (10 points) Make a plot of Trump vote by state. Your plot should include the following 5 states: California, West Virginia, Michigan, Wisconsin, Pennsylvania. Your plot should have state on the X axis and Trump vote on the y axis. Include 95% confidence intervals on your plot (use geom_errorbar in ggplot).
Note: You will be putting all 5 states on one plot
5. (10 points) Explain in your own words what these 95% confidence intervals from the previous plot represent.
6. (10 points) Your friend says to you, “Your use of the t-distribution to construct that confidence interval was problematic because Trump vote share is not normally distributed.” Craft a response to your friend that explains when and why you might use the t-distribution even if the underlying variable you are studying is not normally distributed.
7. (10 points) Using the t.test() function, determine if the difference between the Trump vote in IL vs. TX is ”statistically significant” at the 0.05 level. Explain what this means.
Part 2
8. (20 points) Now, we’re going to run a simulation to demonstrate the role of sampling variation in polling. When survey researchers conduct a survey, they are drawing a sample of respondents, so they can use the sample mean to estimate the population mean. In this question, we will simulate lots of different samples from Survey A respondents to determine how much variation we will see in our predictions as a result of random chance. We will combine this data with electoral vote counts in order to generate predictions about the 2020 presidential election, similar to the 538 election forecast.
CS 340 Milestone One Guidelines and Rubric Overview: For this assignment, you will implement the fundamental operations of create, read, update,
Retail Transaction Programming Project Project Requirements: Develop a program to emulate a purchase transaction at a retail store. This
7COM1028 Secure Systems Programming Referral Coursework: Secure
Create a GUI program that:Accepts the following from a user:Item NameItem QuantityItem PriceAllows the user to create a file to store the sales receip
CS 340 Final Project Guidelines and Rubric Overview The final project will encompass developing a web service using a software stack and impleme