In: Statistics and Probability
Answer to the
question)
Since the comparison is between Dunkin Donuts and Starbucks one can
consider the people who prefer either of it
Like 60 for dunkin donuts and 36 for starbucks , this gives a total sample of size n = 60+36 = 96
Now the claim can be: The proportion of people who prefer dunkin donuts is different than 0.50
[this claim here tries to show that different proportion of people prefer dunking donuts as compared to starbucks. Had it been that people equally liked both the options the proportion for each of them would have been 0.50
But we got the proportion for dunkin donuts as 60/96
So here we need to test if this proportion is significantly larger from 0.50 [neutral liking proportion]
.
Null hypothesis: Proportion of people who like Dunkin donuts P = 0.50
Alternate hypothesis: Proportion of people who like Dunkin donuts P > 0.50
[it is a right tailed test]
.
Test Statistic Z = (P^- P) / sqrt(p*(1-p)/n))
Sample proportion P^= 60/96 = 0.625
n = sample size = 96
.
On plugging these values we get
Z = (0.625-0.50)/sqrt(0.50*0.50/96)
z = 2.45
.
p(Z > 2.45) = 0.007
[refer to z table to obtained the p value]
.
Inference: Since P value 0.007 < level of significance alpha 0.05 , we REJECT the null hypothesis
Conclusion: thus we conclude that there is significant evidence to conclude that the proportion of people who like dunkin donut is MORE than 50%
[since we prove for dunkin donut, and rest of the people in the sample are for starbucks, it automatically gets proved for starbucks as well that the porportion of people who like starbucks is less than 0.50, and hence the two options have difference preferences.]