capstone project
Math 1530 Capstone Project Part II Fall 2012 Solution
5. Presidential election voting. The state of Tennessee voted almost exclusively Republican in recent presidential elections. Question 2 from the survey asked “If you vote in the US Presidential Election this fall, which political party do you prefer?” The options are Democrat (Barack Obama), Republican (Mitt Romney), Other Party. We want to check if there is a relationship between gender and the 2012 presidential election voting of ETSU students. Assume the students who took the class survey are an SRS of ETSU students.
a. Create an appropriate graph to display the data and insert it here. Make sure that you do not include missing or empty cells as a group by checking “Data Options then Group Options” (uncheck missing values).
Use Graph>Bar chart>Cluster or Graph>Bar chart>Stack to create a bar graph. Below is the cluster bar graph. Choose variables “Gender & Vote_Election”
G
E
N
D
E
R
V
O
T
E
_
E
L
E
C
T
I
O
N
M
a
l
e
F
e
m
a
l
e
R
e
p
u
b
l
i
c
a
n
O
t
h
e
r
P
a
r
t
y
D
e
m
o
c
r
a
t
R
e
p
u
b
l
i
c
a
n
O
t
h
e
r
P
a
r
t
y
D
e
m
o
c
r
a
t
2
0
0
1
5
0
1
0
0
5
0
0
C
o
u
n
t
C
h
a
r
t
o
f
G
E
N
D
E
R
,
V
O
T
E
_
E
L
E
C
T
I
O
N
b. Create an appropriate two-way table and insert it here. Make sure that the table will display missing values for “No variable”.
Use Stat > Tables > Cross Tabulation and Chi-square. Click “Options” and check “No variables” for “Display missing Value for”. The output is
|
Tabulated statistics: GENDER, VOTE_ELECTION Rows: GENDER Columns: VOTE_ELECTION Other Democrat Party Republican All Female 179 93 215 487 Male 100 61 132 293 All 279 154 347 780 Cell Contents: Count
|
c. Choose an individual at random. Find the probability that the student is a female and would vote Republican.
215/780 or approximately 0.2756… or 27.56%
d. Find the conditional probability that a student would vote Republican given that the student was a female.
215/487 or approximately 0.4415… or 44.15%
e. Find the conditional probability that a student would vote Republican given that the student was a male.
132/293 or approximately 0.4505… or 45.05%
f. Find the conditional probability that a student was a female given that the student would vote Republican.
215/347 or approximately 0.6196… or 61.96%
g. Carry out a test for the hypothesis that there is no relationship between gender and voting preference in 2012 presidential election of ETSU students. Use α=0.05. Include the appropriate Minitab output to support your conclusions.
Stat>Tables>Cross Tabulation and Chi-Square (choose variables “Gender & Vote_Election”). Be sure “Counts” is checked under “Display” and click on the “Chi-Square” button. Choose to display the “Chi-Square Analysis”
Tabulated statistics: GENDER, VOTE_ELECTION
Rows: GENDER Columns: VOTE_ELECTION
Other
Democrat Party Republican All
Female 179 93 215 487
174.2 96.2 216.7 487.0
0.1325 0.1033 0.0126 *
Male 100 61 132 293
104.8 57.8 130.3 293.0
0.2202 0.1717 0.0210 *
All 279 154 347 780
279.0 154.0 347.0 780.0
* * * *
Cell Contents: Count
Expected count
Contribution to Chi-square
Pearson Chi-Square = 0.661, DF = 2, P-Value = 0.719
Based on Chi-square test results, P-values = 0.719. We do not reject the null hypothesis and conclude that there is not a significant relationship between gender and the 2012 presidential election voting of ETSU students.
6. Working hours. The MATH1530 class survey in fall 2011 showed that 65% of MATH1530 students had at least a part-time job. We want to test whether the percentage of MATH1530 students with at least a part-time job is lower using some sample data from our class survey.
Note: The solution is not unique because of random sampling.
a. Using the survey data as in a population, generate a random sample of size n=30. Record the information in the table below. In Minitab, use Calc > Random Data > Sample from Columns. Note: you can store both ID and WORK_HOURS of your sample in 2 new columns at the same time. Create 2 new variables in worksheet called “Sample ID” and “Sample WkHrs”
|
n |
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
|
ID |
718 |
485 |
606 |
198 |
437 |
444 |
315 |
603 |
766 |
376 |
|
WORK_HOURS |
25 |
60 |
25 |
10 |
0 |
20 |
0 |
10 |
40 |
35 |
|
|
|
|
|
|
|
|
|
|
|
|
n |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
|
ID |
245 |
723 |
781 |
4 |
740 |
468 |
524 |
463 |
546 |
82 |
|
WORK_HOURS |
20 |
0 |
40 |
27 |
30 |
8 |
25 |
0 |
20 |
0 |
|
n |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
|
ID |
626 |
528 |
533 |
55 |
454 |
113 |
648 |
560 |
223 |
417 |
|
WORK_HOURS |
0 |
9 |
0 |
25 |
0 |
0 |
4 |
36 |
22 |
40 |
b. Based on your results in part (a), perform a hypothesis test that the percentage of current MATH1530 students with at least a part-time job is lower than 65%. Answer the following questions.
i. What is the proportion that these 30 students work at least part time? 21/30 =70%
(Note: It could be any one of the values: 0, 1/30, 2/30, …, 30/30)
ii. State the null and alternative hypotheses.
H0: p=.65 Ha: p<.65
iii. Analyze and state your conclusion. Include any output from Minitab here.
Use STAT > Basic Statistics > 1 Proportion.
|
|
|
If using normal approximation for large sample, the output is
Test and CI for One Proportion
Test of p = 0.65 vs p < 0.65
95% Upper
Sample X N Sample p Bound Z-Value P-Value
1 21 30 0.700000 0.837618 0.57 0.717
Using the normal approximation.
If normal approximation for large sample is not used, the output is
Test and CI for One Proportion
Test of p = 0.65 vs p < 0.65
95% Upper Exact
Sample X N Sample p Bound P-Value
1 21 30 0.700000 0.833674 0.775
Both yield similar results. Conclusion based on MY random sample: There is not enough evidence that the percentage of current MATH1530 students with at least a part-time job is lower than 65%.
iv. Examine the data. Are the conditions for inference in part iii met? Justify.
Conditions for inference about a population proportion using large sample test:
· The data is a SRS from the population. The original data were obtained from part of the population (Current MATH1530 students). It was from a voluntary response sampling. We selected a simple random sample from this part of the population. If we feel that the students who took the survey represent the population then we can trust the above conclusions.
· Is n(p-hat) > 15 ? We want our sample to have at least 15 successes.
· Is n(1 - p-hat) > 15 ? We want our sample to have at least 15 failures.
7. Students’ expected salary: Question 10 from the survey asked “What is your expected salary (in dollars) for a secure job in Johnson City if you have finished your intended highest degree?” Is there good evidence that all female college students and all male college students differ in their mean expected salary after they receive their highest degree? Give a 95% confidence interval and interpret your results. What assumptions are we making about the samples for our interpretation to be valid?
This is a 2-sample t test. In Minitab, use Stat>Basic Statistics > 2 sample t. We do not check “Assume equal variances” based on the sample variances we obtained earlier.
Descriptive Statistics: SALARY_EXPECTED ($)
Variable GENDER N N* Mean SE Mean StDev Minimum Q1
SALARY_EXPECTED ($) Female 436 56 83404 3311 69137 15000 50000
Male 268 28 95265 5677 92934 10000 50000
Variable GENDER Median Q3 Maximum
SALARY_EXPECTED ($) Female 66920 90000 700000
Male 75000 100000 850000
The Minitab Output for the two-sample t test is:
Two-Sample T-Test and CI: SALARY_EXPECTED ($), GENDER
Two-sample T for SALARY_EXPECTED ($)
GENDER N Mean StDev SE Mean
Female 436 83404 69137 3311
Male 268 95265 92934 5677
Difference = mu (Female) - mu (Male)
Estimate for difference: -11862
95% CI for difference: (-24777, 1054)
T-Test of difference = 0 (vs not =): T-Value = -1.80 P-Value = 0.072 DF = 447
The 95% confidence interval is (-24,777, 1,054).
Based on the given sample data, we are 95% confident that the difference between male and female students in the mean of their expected salary after they receive their highest degree is somewhere between -24,777 and 1,054 dollars.
The hypothesis testing shows a p-value of 0.072. This indicates that at significance level 0.05 there is not enough evidence that all female college students and all male college students differ in their expected salary after they receive their highest degree. NOTE: The conclusion depends on the significance level. If the significance level is greater than 0.072, e.g., 0.1, we would be able to reject the null hypotheses.
A 95% confidence interval for µF − µM (the difference in the true mean of their expected salary after they receive their highest degree) is between -24,777 and 1,054 dollars. Since 0 is between these two numbers there appears to be insufficient evidence to suggest that all female college students and all male college students differ in their expected salary after they receive their highest degree.
We are assuming that the data presented is a representative/random sample of all college students, as well as separately for male and female college students.
Comments:
a. The students that responded to this question are not a random sample of all college students. Hence, the t-interval may be meaningless.
b. We may be able to argue that these samples represent a random sample of ETSU students since nearly all students take Math 1530.
c. Both distributions are skewed right (from the histograms and Boxplots) which should not be a major concern since both sample sizes are quite large.
8. (Bonus) Who will win the 2012 presidential election? “Most Americans still predict Obama will win 2012 election”, said Gallup.com on August 27 (http://www.gallup.com/poll/156914/americans-predict-obama-win-2012-election.aspx). The results of the poll revealed the following: 58% of the respondents said that Obama will win the election while 36% of the respondents believe Romney will win the election. We will assume 6% of the respondents think the other party will win.
Question 4 from the survey asked “Who do you think will win the 2012 US Presidential Election?” Variable ELECTION_WINNER represents the responses from MATH1530 students. There are three options (Obama, Romney, and other). Assume that the students who responded the survey are from an SRS of all ETSU students.
Is there good evidence that ETSU students’ prediction is different from the Gallup prediction? Perform a test of hypothesis using α=0.05. What is your conclusion? Note: Minitab 16 should be used to answer this question.
Use Stat> Tables> Chi-square Goodness-of-fit (one Variable)…
The Minitab output is:
Chi-Square Goodness-of-Fit Test for Categorical Variable: WON_ELECTION
Test Contribution
Category Observed Proportion Expected to Chi-Sq
Barack Obama 476 0.58 452.4 1.23112
Mitt Romney 260 0.36 280.8 1.54074
Other 44 0.06 46.8 0.16752
N N* DF Chi-Sq P-Value
780 8 2 2.93939 0.230
Since P-values is 0.23, we do not reject the null hypothesis and conclude that there is not enough evidence to suggest that ETSU students’ prediction is different from the Gallup prediction on August 27, 2012.