Lecture 18 Slides
.pdfAnalogy
Consider an accused person in court.
H0: not guilty, Ha: guilty
Reject H0, accept Ha =) send to prison
Not reject H0 =) let him go
Usually, H0 means that some e ect does not exist, Ha means it exists
11/22
A test is defined by a function
f(X1; : : : ; Xn)
of a sample X1; : : : ; Xn, where f takes values 1 or 0 (reject/not reject).
The function f may take di erent values for di erent realizations of a sample X1(!); : : : ; Xn(!) =) the conclusion is random.
12/22
Testing hypothesis about the mean of a population
Our standard setting will be as follows.
The null hypothesis: |
H0 : = 0 |
|
The alternative hypothesis: |
Ha : = 1 |
(simple alternative) |
|
Ha : 6= 0 |
(two-sided alternative) |
|
Ha : < 0 |
(one-sided alternatives) |
|
Ha : > 0 |
13/22
Example
Suppose the population is normal, N( ; 2). We want to test
H0 : = 0; Ha : 6= 0
Example 1. Suppose we have the sample of 10 elements
0:96; 1:67; 1:44; 1:45; 1:05; 0:16; 0:69; 0:84; 1:1; 1:08
Solution: construct a 95% confidence interval,
sb
= X t0:025(9)p
10
14/22
We have
= 0:754 0:63 at the confidence level 95% Thus it is unlikely that = 0 so we reject H0.
15/22
Example 2
Suppose in the same example we obtained the sample (from another population)
0:72; 0:49; 0:05; 0:19; 0:52; 0:80; 1:87; 1:39; 0:46; 2:05
The 95% confidence interval is
= 0:072 0:81
We cannot reject H0 : = 0.
16/22
Type I and Type II errors
The conclusion (reject/not reject H0) may be wrong.
Type I error: reject H0 when H0 is true
Type II error: not reject H0 when H0 is false
17/22
The probability of type I error of a test is denoted by :
= P(reject H0 j H0 is true)
The probability of type II error of a test is denoted by :
= P(not reject H0 j H0 is false)
is the significance of the test.
1 is the power of the test.
18/22
Example
The proportion of defective items produced by a plant was 9%. Improvement has been made with the goal to reduce the rate to 5%.
Consider the following test:
Randomly select n = 200 details and if the number of defective details is not greater than m = 8 the improvement is considered as successful, otherwise unsuccessful.
19/22
Let X Bernoulli(p) is the current rate of defective items. We want to test
H0 : p = 0:09 |
Ha : p = 0:05 |
Then |
|
X Bernoulli(0:09) under H0; |
X Bernoulli(0:05) under Ha: |
20/22