In: Statistics and Probability
Case Problem A Bipartisan Agenda for Change ( Need to Use R coding)
In a study conducted by Zogby International for the Demaocrat and Chronicile, more than 700 New Yorkrs were polled to dtermine whether the New York state government works. Respondent survyed were asked questions involving pay cuts for state legislators, restrictions on lobbyists, term limits for legislators, and whethr stat citizens should be able to put matters directly on the state ballot for a vote.The results regarding several proposed reforms had broad support, crossing all demographic and political lines.
Suppose that a follow-up survey of 100 individuals who live in the western region of New York was conducted. The party affiliation (emocrat, Independent, Republican) of each individual surveyed was recored, as well as their responses to the following three questions.
1. Should legislative pay be cut for every day the state budget is late? (Yes / No)
2. Should there be more restrictions on lobbyists? (Yes / No)
3. Should there be term limits requiring that legislators serve a fixed number of years? (Yes / No)
The responses were coded using 1 for a Yes response and 2 for a No response. The complete
data set is available in the file named NYReform.
Managerial Report (My Questions are below the managerial report)
1. Use descriptive statistics to summarize the data from this study. What are your preliminary
conclusions about the independence of the response (Yes or No) and party
affiliation for each of the three questions in the survey?
2. With regard to question 1, test for the independence of the response (Yes and No)
and party affiliation. Use α _ .05.
3. With regard to question 2, test for the independence of the response (Yes and No)
and party affiliation. Use α _ .05.
4. With regard to question 3, test for the independence of the response (Yes and No)
and party affiliation. Use α _ .05.
5. Does it appear that there is broad support for change across all political lines? Explain.
These are the questions I need to answer specifically.
a)First, we will look at potential differences in political affiliation when it comes to the topic of pay cut for late budgets. For this, look at the answers for question1 (refers to question 1 out of 3 in the problem description) depending on the political affiliation. Specifically, fill in the following contingency table based on the data in the csv.
b) Now, we are interested in potential differences across the three political affiliations with respect to the percentage of people answering 'YES'. What type of test would you run for this, and why?
c) What are the hypotheses for this test? Specify them here, and describe their meaning for this problem.
d) Conduct the test suggested in part b and c, using alpha = 0.05 and the table created in part a (note: you can create the table in Excel, save it as csv, read it into R, and run the test in R). Show the test statistic and the corresponding p-value. What is your conclusion?
e) Now, to identify which political affiliations might be different from each other, run the multiple comparison Marascuilo test. Which political affiliations differ from each other in their answers to question 1 (refers to question 1 out of 3 in the problem description)?( USE R)
f) Finally, with regard to question 2 (lobbying) in the problem description, test for the independence of the response (Yes and No) and party affiliation at the level alpha = 0.05. What is your conclusion?
Observation | Party | Pay Cut? | Lobbyists? | Term Limits? |
1 | Democrat | 1 | 2 | 2 |
2 | Democrat | 1 | 1 | 2 |
3 | Democrat | 2 | 1 | 2 |
4 | Democrat | 1 | 2 | 1 |
5 | Democrat | 2 | 2 | 2 |
6 | Democrat | 2 | 1 | 1 |
7 | Democrat | 1 | 2 | 2 |
8 | Democrat | 2 | 1 | 2 |
9 | Democrat | 1 | 1 | 2 |
10 | Democrat | 1 | 2 | 1 |
11 | Democrat | 1 | 2 | 1 |
12 | Democrat | 1 | 2 | 1 |
13 | Democrat | 2 | 2 | 1 |
14 | Democrat | 1 | 2 | 1 |
15 | Democrat | 1 | 1 | 1 |
16 | Democrat | 1 | 2 | 2 |
17 | Democrat | 1 | 1 | 2 |
18 | Democrat | 1 | 2 | 1 |
19 | Democrat | 1 | 1 | 2 |
20 | Democrat | 1 | 1 | 1 |
21 | Democrat | 2 | 2 | 1 |
22 | Democrat | 1 | 2 | 2 |
23 | Democrat | 2 | 1 | 2 |
24 | Democrat | 2 | 1 | 1 |
25 | Democrat | 2 | 1 | 1 |
26 | Democrat | 1 | 1 | 1 |
27 | Democrat | 1 | 1 | 2 |
28 | Democrat | 2 | 1 | 1 |
29 | Democrat | 2 | 2 | 2 |
30 | Democrat | 1 | 1 | 2 |
31 | Democrat | 1 | 2 | 2 |
32 | Democrat | 2 | 1 | 1 |
33 | Democrat | 1 | 1 | 2 |
34 | Democrat | 2 | 1 | 1 |
35 | Democrat | 2 | 1 | 2 |
36 | Democrat | 1 | 1 | 2 |
37 | Independent | 2 | 2 | 1 |
38 | Independent | 2 | 2 | 1 |
39 | Independent | 1 | 1 | 1 |
40 | Independent | 1 | 1 | 2 |
41 | Independent | 2 | 1 | 2 |
42 | Independent | 2 | 2 | 1 |
43 | Independent | 1 | 1 | 2 |
44 | Independent | 2 | 1 | 1 |
45 | Independent | 1 | 1 | 1 |
46 | Independent | 2 | 1 | 2 |
47 | Independent | 1 | 1 | 1 |
48 | Independent | 1 | 1 | 1 |
49 | Independent | 2 | 1 | 2 |
50 | Independent | 2 | 2 | 1 |
51 | Independent | 1 | 1 | 2 |
52 | Independent | 1 | 1 | 1 |
53 | Independent | 1 | 1 | 2 |
54 | Independent | 1 | 1 | 2 |
55 | Independent | 2 | 1 | 2 |
56 | Republican | 1 | 1 | 1 |
57 | Republican | 1 | 2 | 1 |
58 | Republican | 1 | 1 | 2 |
59 | Republican | 1 | 1 | 1 |
60 | Republican | 2 | 1 | 2 |
61 | Republican | 1 | 1 | 2 |
62 | Republican | 1 | 1 | 2 |
63 | Republican | 1 | 1 | 1 |
64 | Republican | 1 | 1 | 1 |
65 | Republican | 1 | 1 | 1 |
66 | Republican | 1 | 1 | 2 |
67 | Republican | 1 | 1 | 2 |
68 | Republican | 1 | 2 | 1 |
69 | Republican | 1 | 2 | 1 |
70 | Republican | 1 | 1 | 1 |
71 | Republican | 2 | 2 | 1 |
72 | Republican | 2 | 1 | 1 |
73 | Republican | 1 | 1 | 1 |
74 | Republican | 2 | 2 | 1 |
75 | Republican | 2 | 1 | 1 |
76 | Republican | 1 | 2 | 1 |
77 | Republican | 1 | 2 | 1 |
78 | Republican | 1 | 1 | 2 |
79 | Republican | 1 | 1 | 1 |
80 | Republican | 1 | 1 | 1 |
81 | Republican | 1 | 2 | 1 |
82 | Republican | 1 | 2 | 2 |
83 | Republican | 2 | 1 | 2 |
84 | Republican | 1 | 1 | 1 |
85 | Republican | 1 | 1 | 2 |
86 | Republican | 1 | 1 | 1 |
87 | Republican | 1 | 1 | 2 |
88 | Republican | 1 | 1 | 2 |
89 | Republican | 1 | 1 | 1 |
90 | Republican | 1 | 1 | 1 |
91 | Republican | 1 | 1 | 1 |
92 | Republican | 1 | 1 | 1 |
93 | Republican | 1 | 1 | 1 |
94 | Republican | 1 | 1 | 1 |
95 | Republican | 1 | 1 | 1 |
96 | Republican | 1 | 2 | 1 |
97 | Republican | 1 | 1 | 1 |
98 | Republican | 1 | 1 | 1 |
99 | Republican | 1 | 2 | 2 |
100 | Republican | 1 | 1 | 1 |