Hypothesis Test
Hypothesis Test
Hypothesis Test
Hypothesis Testing
BY UNSA SHAKIR
Sample data is used to estimate parameters of a
population
Statistics are calculated using sample data.
Parameters are the characteristics of population data
• Mean = x
i 1
x
n
s i 1
n 1
• Estimation
• Hypothesis testing
Calculate a p-value
Complement of the
null hypothesis
Stating a Hypothesis
Example:
Write the claim as a mathematical sentence. State the null
and alternative hypotheses and identify which represents the
claim.
Statesville college claims that 94% of their graduates find
employment within six months of graduation.
p = 0.94
Complement of the
null hypothesis
Types of Errors
No matter which hypothesis represents the claim, always
begin the hypothesis test assuming that the null
hypothesis is true.
x 0 185 170
zstat 3.00
SEx 5
P-values
• If the null hypothesis is true, a P-value (or probability
value) of a hypothesis test is the probability of obtaining a
sample statistic with a value as extreme or more extreme
than the one determined from the sample data.
z
-3 -2 -1 0 1 2 3
Test
statistic
Right-tailed Test
2. If the alternative hypothesis contains the greater-than
symbol (>), the hypothesis test is a right-tailed test.
H0 : μ k
Ha : μ > k
P is the area to
the right of the
test statistic.
z
-3 -2 -1 0 1 2 3
Test
statistic
Two-tailed Test
3. If the alternative hypothesis contains the not-equal-to
symbol (), the hypothesis test is a two-tailed test. In a
1
two-tailed test, each tail has an area of 2 P.
H0 : μ = k
Ha : μ k
P is twice the
P is twice the area to the right
area to the left of of the positive
the negative test test statistic.
statistic.
z
-3 -2 -1 0 1 2 3
Test Test
statistic statistic
Accept the null hypothesis if the sample
statistic falls in this region
Acceptance
Region Rejection
/Critical Region
H0: p 0.125
Left-tailed test
Identifying Types of Tests
Example:
For each claim, state H0 and Ha. Then determine whether
the hypothesis test is a left-tailed, right-tailed, or two-tailed
test.
H0: μ = 8 (Claim)
Ha: μ 8
Two-tailed test
Making a Decision
Decision Rule Based on P-value
To use a P-value to make a conclusion in a hypothesis test,
compare the P-value with .
1. If P , then reject H0.
2. If P > , then accept H0.
Claim
Decision Claim is H0 Claim is Ha
There is enough evidence to r There is enough evidence to s
Reject H0 eject the claim. upport the claim.
There is not enough evidence There is not enough evidence
Accept H0 to reject the claim. to support the claim.
Interpreting a Decision
Example:
You perform a hypothesis test for the following claim. How
should you interpret your decision if you reject H0? If you
fail to reject H0?
=?
3. Determine the standardized sampling
distribution and draw its graph. z
0
Yes
Reject H0.
7. Write a statement to interpret the decision in the context of
the original claim.
z= = x– μ
σ/√n
= 1.897
Step 3: Set Rejection Region
1.65
Step 4: Conclude
We can see that 1.897 > 1.65, thus our test statistic is in
the rejection region. Therefore we accept the null
hypothesis.
ILLUSTRATION
ONE TAILED (RIGHT TAILED)
H0 : μ ≥ 30
H1 : μ < 30 (RIGHT TAILED)
Z= x– μ
σ/√n
= -3.727
STEP 3: SET REJECTION REGION
STEP 4: CONCLUDE
z = 40,900-40,000 = 3
300
At 0.01 level, the critical value of z is
2.33. Z tab > Z cal
Accept
Zcal=3
As computed
value falls in
rejection region,
.01
we reject the
null hypothesis.
Example:
A manufacturer claims that at least 95% of the
equipment that he supplied to a factory conformed
to specifications. An examination of 700 pieces of
equipment reveals that 53 are faulty. Do these
results provide sufficient evidence to reject the
manufacturer's claim? Use α= 0.01 to perform the
test.
1. Ho: p = 0.95 , H1: p <0.95
2. α= 0.01
3. z= -3.1341
4. Reject Ho
Ho accepted.
Example:
A random sample of boots worn by 40 combat
soldiers in a desert region showed an average
life of 1.08 yrs with a standard deviation of
0.05.Under the standard conditions,the boots
are known to have an average life of 1.28 yrs.Is
there reason to assert at a level of significance
of 0.05 that use in the desert causes the mean
life of such boots to decrease?
Ans: Ho rejected.
Example:
ABC company is engaged in the packaging of a
superior quality tea in jars of 500 gm each.The
company is of the view that as long as jars
contain 500 gm of tea, the process is in
control.The standard deviation is 50 gm.A sample
of 225 jars is taken at random and the sample
average is found to be 510 gm.Has the process
gone out of control?