You are on page 1of 13

Chapter 6

Hypothesis Testing
Single Population
Week 7
L4 - Confidence Interval
L5 - Hypothesis Test about the Normal
Mean, Variance Unknown
July 14 1
Learning Outcomes:
At the end of the lesson student should be able
to
- Determine the confidence interval for
hypothesis test with variance known;
- Perform hypothesis test about normal mean
when variance is unknown;
- calculate the P-value of a hypothesis test;

July 14
2
Definitions
Confidence interval: Based on sample data, two numbers are
calculated to form an interval within which the parameter is
expected to lie.
The probability that a confidence interval will contain the
estimated parameter is called the confidence coefficient,
designated by 1 o.
A Confidence level of 95% ( o = 0.05) implies that 95% of all
samples would give an interval that includes the parameter that
is being estimated, and only 5% of all sample would yield an
erroneous interval.
Most frequently used confidence levels are 95%, 99% and 90%
Width of interval provides information about the precision of an
interval estimate
July 14
3
One of the 20 intervals fails to contain .
In a 95% CI, expect 95% or 19 out of 20, will perform as
planned and contain within their upper bound and lower
bound.
July 14
4
A 100 (1- o )% confidence level for the mean of a normal
population when the value of o is known is given by
)] )( ( ), )( ( [
2 / 2 /
n
z x
n
z x
o o
o o
+
or equivalently
) )( ( ) )( (
2 / 2 /
n
z x
n
z x
o

o
o o
+ s s
CI FOR NORMAL MEAN
WHEN VARIANCE IS KNOWN
July 14
5
Example question on hypothesis test
Standards set by government agencies indicate that
Malaysians should not exceed the average daily sodium
intake of 3300 milligrams (mg). Standard deviation of
The daily sodium intake is 1100 mg. To find out whether
Malaysians are exceeding this limit, a sample of 100
Malaysians is selected, and the mean is found to be 3400
mg. At 5% significance level,
a) is there evidence to support the claim the mean daily
sodium intake exceeds 3300mg?
b) Test for conformance to the health requirement using p-
value.
c) Construct 95% CI on the mean daily sodium intake.
July 14
6
1. Problem: To test about the mean, variance known.
2. Null hypothesis H
0
: = 3300 ; Alternative hypothesis H
1
: >
3300
3. Test statistics:

4. Critical value:

5. Reject region:

6. Calculation:

7. Conclusion:
Solution:
n /
X
Z
0
o

=
645 . 1
05 . 0
= = z z
o
645 . 1 = >
o
z Z
Since z < 1.645, we fail to reject reject H
0
: = 3300mg
There is not enough evidence that the average daily sodium intake
exceeds 3300mg.
91 . 0
100 / 1100
3300 3400
, 1100 and 3400 Since =

= = = z x o
July 14
7
(b) Use p - value:
p-value = 1- = 1- 0.8186 = 0.1814
Since p -value > (=0.05), we fail to reject H
0

Based on sample of 100 measurements, the average daily
sodium intake does conforms with health requirement.

(c)





The 95% CI: [3184.4, 3615.6]
n
z
x
n
z
x
o

o
o o 2 / 2 /
+ s s
6 . 3615 4 . 3184
6 . 215 3400 6 . 215 3400
100
1100 ) 96 . 1 (
100
1100 ) 96 . 1 (
s s
+ s s
+ s s

x x
July 14
8
) 91 . 0 ( u
Definitions
In conducting experiment to evaluate a new but very costly
Process for producing synthetic diamonds, you are able to study
only six diamonds generated by the process.

How can you use these 6 measurements to make inferences
about the average weight of diamonds from this process?
Recall:
i. if original sampled population is normal, then have a
normal population for any sample size.
ii. if original sampled population is not normal, then have a
normal population if ( CLT)
X
X
30 > n
When sample size n is small, does not have a normal
Distribution
X
When sample size n is small, we use the t distribution.
July 14
9
Density of T (v)
Graph of Density T (v)
2
1
2
2
2
1
x 1 ) x ( f
+ v

v
+ v
+
I vt
I
=
July 14
10
o = > v
v o,
t T P ) ( t ~ T
o 0.975 0.95 0.50 0.05 0.025
v
5 -2.571 -2.015 0 2.015 2.571
120 -1.9809 -1.658 0 1.658 1.9809
-1.960 -1.645 0 1.645 1.960
July 14
11
TEST ABOUT NORMAL MEAN
WHEN VARIANCE IS UNKNOWN
Three Test Problems about Normal mean :
1. H
0
: =
0
(or ) against H
1
: >
0
2. H
0
: =
0
(or ) against H
1
: <
0
3. H
0
: =
0
against H
1
:
The Key:
Test Statistic
T ~ t(n-1) if =
0
n / S
X
T
0

=
Critical Region: (Respective regions: Reject H
0
)
1.
2.
3.
0
s
0
>
0
=
-1 n ,
t T
o
>
-1 n ,
t T
o
<
-1 n /2, -1 n /2, -1 n /2,
t T or t T : t | T | > < >
July 14
12
P- values in Hypothesis Testing
Calculate P-value :





When P < , reject H
0

When P , fail to reject H
0

Normal Distribution t- Distribution
Upper-tailed test
P-value = 1- (z)

P-value = P(T
n-1
> t)
Lower-tailed test
P-value = (z) P-value = P(T
n-1
< t)
Two-tailed test
P-value = 2[1-(|z|) ] P-value = 2P(T
n-1
> |t|)
July 14
13

You might also like