Difference between revisions of "Hypothesis Testing"
(→A ProblemM. K. Chung's lecture notes, 2003.) |
|||
Line 19: | Line 19: | ||
One reasonable thing one may try is to see how high the sample mean is. | One reasonable thing one may try is to see how high the sample mean is. | ||
− | < | + | <syntaxhighlight lang="r" line='line'> |
> x<-c(30, 25, 70, 110, 40, 80, 50, 60, 100, 60) | > x<-c(30, 25, 70, 110, 40, 80, 50, 60, 100, 60) | ||
> mean(x) | > mean(x) | ||
[1] 62.5 | [1] 62.5 | ||
− | </ | + | </syntaxhighlight> |
I believe that dogs are as smart as people. Assume IQ of a dog follows [math]Xi \sim N(\mu,102)[/math]. IQ of 10 dogs are measured: 30, 25, 70, 110, 40, 80, 50, 60, 100, 60. We want to test if dogs are as smart as people by testing
[math]H_0 : \mu = 100 \text{vs.} H_1 : \mu \lt 100[/math].
One reasonable thing one may try is to see how high the sample mean is.
1 > x<-c(30, 25, 70, 110, 40, 80, 50, 60, 100, 60)
2
3 > mean(x)
4 [1] 62.5
References
hkilter.com by H. K. Ilter is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License
© 2020 H. K. Ilter