Answer: False. From the point estimate we know that 46% of Americans in the sample support the decision.
Answer: True. Out of 100 sample drawn 95 sample Americans decision will lie between 43% and 49% confidence interval.
Answer: True. 95% sample decision will be between 43% and 49%.
Answer: False. For same standard error 90% confidence interval will have a lower margin of error. # 6.12 Legalization of marijuana, Part I. The 2010 General Social Survey asked 1,259 US res- idents: âDo you think the use of marijuana should be made legal, or not?â 48% of the respondents said it should be made legal.
Answer: It’s a sample statistic because it’s collected from a subset of the population.
Answer:
n <- 1259
p <- 0.48
se <- sqrt((p*(1-p))/n)
t <- qt(0.975,n-1)
me <- t * se
p-me
## [1] 0.4523767
p + me
## [1] 0.5076233
95% confidence interval is (0.4523767, 0.5076233), out of 100 sample surveys 95 will have the survey result will be between the interval.
Answer: It’s true for the data. Two things must need to be satisfied for the data to be normally distributed. The sample is independent since collected from a survey.For success failure condition is also satisfied since \(\hat{p}\) = 48% of 1259 is greater than 10.
Answer: It’s not justified since 95% confidence interval is below 51% which is almost half of the total respondent..
Woods Cultivated grassplot Deciduous forests Other Total 4 16 61 345426 (a) Write the hypotheses for testing if barking deer prefer to forage in certain habitats over others.
Answer: Null Hypothesis: Barking deer has no preference for foraging in certain habitats over Others Alternative Hypothesis: Barking deer has preference for foraging in certain habitats over others.
Answer: We can chi squared test to answer this research question.
Answer: Independence of observations is satisfied since each area is counted once .
Expected cell counts need to be greater or equal to 5. For woods habitat expected cell count is 0.048*426 = 20.49. Hence the second assumption is also satisfied.
Answer:
obsTotal <- c(4/426, 116/426, 67/426, 345 / 426)
popTotal <- c(0.048,0.147,0.396, (1-0.048+ 0.147+0.396))
chisq.test(obsTotal, popTotal)
## Warning in chisq.test(obsTotal, popTotal): Chi-squared approximation may be
## incorrect
##
## Pearson's Chi-squared test
##
## data: obsTotal and popTotal
## X-squared = 12, df = 9, p-value = 0.2133
Since the p value of the test 0.2133 > 0.05 at 5% level of significance we don’t reject the null hypothesis. We conclude that there is no evidence that barking deer prefer one type of grazing land over another.
Caffeinated coffee consumption â¤1 2-6 1 2-3 â¥4 cups/day 95 2,288 2,383 cup/week Clinical Yes 670 depression No 11,545 Total 12,215 cups/week 6,244 6,617 cup/day 905 16,329 17,234 cups/day 564 11,726 12,290 Total 2,607 48,132 50,739
What type of test is appropriate for evaluating if there is an association between coffee intake and depression? Answer: A chi-squared test will be appropriate here.
Write the hypotheses for the test you identified in part (a).
Answer: Null Hypothesis: Coffee consumption and clinical depression are independent.
Alternative Hypothesis: Coffe consumption and clinical ddpression are dependent.
Answer:
round(2607/50739,2)
## [1] 0.05
round(1-2607/50739,2)
## [1] 0.95
5% suffer from depression and 95% don’t suffer from depression.
expected <-round( 2607*6617/50739)
expected
## [1] 340
(373-expected)^2/expected
## [1] 3.202941
Expected count for the cell is 340 and the ammount it contributes is 3.202941.
Answer:
pchisq(20.93,4,lower.tail = FALSE)
## [1] 0.0003269507
The p value is 0.0003269507
Answer: Sine the p value is less than 0.05 we reject the null hypothesis and conclude that coffee consumption and depression are related.
Answer: Yes. I agree . The studies statistical significance doesn’t necessarily implies clinical significance difference. More resarch needs to be done before recommending coffee.