Difference between revisions of "Hypothesis Testing"
(→A ProblemM. K. Chung's lecture notes, 2003.) |
(→A ProblemM. K. Chung's lecture notes, 2003.) |
||
Line 32: | Line 32: | ||
<center>{{#tag:math|X_i \sim N(100,10^2)}}</center> | <center>{{#tag:math|X_i \sim N(100,10^2)}}</center> | ||
+ | |||
Under this condition, {{#tag:math|\bar{X} \sim N(100, 10)}} and | Under this condition, {{#tag:math|\bar{X} \sim N(100, 10)}} and | ||
Line 37: | Line 38: | ||
<center>{{#tag:math|\alpha = P(\bar{X} \leq 90) }}</center> | <center>{{#tag:math|\alpha = P(\bar{X} \leq 90) }}</center> | ||
− | <syntaxhighlight lang="r | + | |
+ | <syntaxhighlight lang="r"> | ||
> pnorm(90,100,sqrt(10)) | > pnorm(90,100,sqrt(10)) | ||
[1] 0.0007827011 | [1] 0.0007827011 |
I believe that dogs are as smart as people. Assume IQ of a dog follows [math]X_i \sim N(\mu,10^2)[/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
One reasonable thing one may try is to see how high the sample mean is.
> x<-c(30, 25, 70, 110, 40, 80, 50, 60, 100, 60)
> mean(x)
[1] 62.5
Since the average IQ of 10 dogs are lower than 100, one would be inclined to reject [math]H_0[/math].
Let [math]\bar{X} [/math] be a test statistic and [math]R = (−∞,90][/math] to be a rejection region. Let’s compute the probability of making Type I error based on this testing procedure. Under the assumption [math]H_0[/math] is true,
Under this condition, [math]\bar{X} \sim N(100, 10)[/math] and
> pnorm(90,100,sqrt(10))
[1] 0.0007827011
References
hkilter.com by H. K. Ilter is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License
© 2020 H. K. Ilter