Académique Documents
Professionnel Documents
Culture Documents
PGDM(2017-19)
Term-II (Sep-Dec,2017)
Kakali Kanjilal
Associate Professor, Operations
IMI, Delhi
Tests of Hypothesis
- Concepts of hypothesis
- Null and Alternative Hypotheses
- Type I, Type II Errors and Power of the Test
- Tests of hypotheses:
I. Population Mean (Single and Two Population)
a. known
b. unknown
II. Population Proportions (Single and Two Population)
III. Population Variance (Single and Two Population)
IV. Tests of Independence
Steps of Hypothesis Testing
Step 1: Develop the null and alternative hypotheses.
H0 and H1 are:
Mutually exclusive: Only one can be true.
Exhaustive: Together they cover all possibilities, so one or the
other must be true.
Develop Null and Alternative
Hypotheses
Example:
A new teaching method is developed that is
believed to be better than the current method
Alternative Hypothesis: H1
The new teaching method is better.
Null Hypothesis: H0
The new method is no better than the old method.
Alternative Hypothesis: H1
The label is incorrect. < 67.6 ounces.
H 0 : 0 H 0 : 0 H 0 : 0
H a : 0 H a : 0 H a : 0
H0 True H0 False
Conclusion
Accept H0 Correct
Type II Error
Decision
Correct
Reject H0 Type I Error
Decision
General Rule to select
Type I error and Type II error
Cases where Type-I error is more costly, we choose a small
value of , namely 1%
For two tailed test, double the tail area to obtain the
p value.
Critical Value Approach
f(z)
Critical Region Critical Region
Acceptance
0.025% Region 0.025%
Total = 5% Level
95%
s
x z / 2 6.1 2.17(.2 30) 6.1 .07924
n
or 6.02076 to 6.17924
p p0
z
s p
where:
p0 (1 p0 )
s p
n
Population 1
Population 2
Cognizant Stock Return
WIPRO Stock Return
1 = mean return
of Cognizant 2 = mean return of WIPRO
1 2 = difference between
the mean returns of two populations
x1 - x2 = Point Estimate of 1 2
Steps of Hypothesis Testing
Step 1: Develop the null and alternative hypotheses.
H 0 : 1 2 D0 H 0 : 1 2 D0 H 0 : 1 2 D0
H a : 1 2 D0 H a : 1 2 D0 H a : 1 2 D0
Left-tailed Right-tailed Two-tailed
1 is the mean of population 1 and 2 is the mean of
population 2.
The difference D0 between the two population means is
1 - 2 .
D0 can be positive or negative or zero. D0 = 0 is the most
common form of the test.
Test Statistic About 1 - 2
s12 s2
2
( x x ) z
1 2 n n
1 2
2
Test Statistic About 1 - 2
Case II: Test Statistic is t (Students t-Statistic)
When Population standard deviations 1 and 2 are unknown and
have to be estimated from two samples
(x x ) ( )
t= 1 2 1 20
2 1
sp
1
n n
1 2
Assuming that the population variances 12 and 22 are equal (even though
unknown), the statistic follows students t distribution with (n1 + n2 2) degrees
of freedom.
Under this assumption, the two sample variances, s12 and s22, provide two
separate estimators of the common population variance.
Combining the two separate estimates into a pooled estimate sp2 should give
us a better estimate than either sample variance by itself.
Pooled Estimate of the Population
Variance
A pooled estimate of the common population variance,
based on a sample variance s12 from a sample of size n1 and
a sample variance s22 from a sample of size n2 is given by:
( n 1) s 2
( n 1) s 2
s 2p 1 1 2 2
n1 n2 2
The degrees of freedom associated with this estimator is:
df = (n1+ n2-2)
That is, larger weight is given to the variance from the larger
sample.
Confidence Intervals for the
Difference between Two Population
Means: 1 - 2
Case II: Test Statistic is t (Students t-Statistic)
When Population standard deviations 1 and 2 are unknown and
have to be estimated from two samples; using the pooled
variance Sp2
2 1 1
( x1 x2 ) t sp
n1 n2
2
Hypothesis Tests
About 1 2: Matched Samples
Possible Situations
I: Difference between two population means is 0
1 - 2 = d
H0: d = 0
H1: d 0
II: Difference between two population means is less than 0
d
H0: d 0
H1: d 0
Test Statistic
Test statistic for the paired - observatio ns test
t d d , df n 1
S
d
n
d t 2 sd
n
H 0 : p1 p2 0 H
H00:: pp1
- p2 < 0
1 p2 0 H 0 : p1 p2 0
H a : p1 p2 0 H
Ha:: pp1
- pp2 > 00 H a : p1 p2 0
a 1 2
x1
p
Where 1 n is the sample proportion for sample 1
1
x2
and
p 2 is the sample proportion for sample 2
n2
stands for a pooled estimator
p
np n p
1 1 2 2
p
n1 n2
Problems
CASES
CASES (using Excel)
SENSEX RETURNS
Test of Hypothesis for Population
Variance:
The Chi-Square (2) Distribution
Confidence intervals for the population variance are based
on the chi-square (2) distribution.
xi x
n 2
With 5 degrees
of freedom
With 10 degrees
of freedom
2 distribution
s2
The chi-square distribution approaches a normal as the
degrees
has of freedom
a chi - square increase.
distribution with (n - 1) degrees of freedom.
Interval Estimation of s2
2
We will use the notation to denote the value for the
chi-square distribution that provides an area of to the
right of the stated value.
2
.975
2
2 .025
2
Interval Estimation of s2
( n 1)s 2
.975
2
.025
2
s2
.025
.025
95% of the
possible 2 values
2
0 .975
2
.025
2
( n 1) s 2 ( n 1) s 2
In general, s 2
;
2
1 2
2
2
Selected Values from the Chi-Square
Distribution Table
For n - 1 = 10 - 1 = 9 d.f. and = .05
2
Our 0.975 value 2
Our .025 value
Hypothesis Test of s2
Hypotheses
Left tail Right tail Two Tail
H 0 : s 2 s 02 H 0 : s 2 s 20 H 0 : s 2 s 20
Ha : s s 2 2
0
H a : s 2 s 20 H a : s 2 s 20
Test Statistic ( n 1) s 2
2
s 20
n1 1 s
2 2
Fn 1, n 1 1
; 1
1 2
n2 1 s
2
2
2
2
1.0 F(25,30)
f (F)
k2 0.7
1 161.4 199.5 215.7 224.6 230.2 234.0 236.8 238.9 240.5
0.6
2 18.51 19.00 19.16 19.25 19.30 19.33 19.35 19.37 19.38
3 10.13 9.55 9.28 9.12 9.01 8.94 8.89 8.85 8.81 0.5
4 7.71 6.94 6.59 6.39 6.26 6.16 6.09 6.04 6.00
0.4
f(F )
5 6.61 5.79 5.41 5.19 5.05 4.95 4.88 4.82 4.77
6 5.99 5.14 4.76 4.53 4.39 4.28 4.21 4.15 4.10 0.3
7 5.59 4.74 4.35 4.12 3.97 3.87 3.79 3.73 3.68 0.2
8 5.32 4.46 4.07 3.84 3.69 3.58 3.50 3.44 3.39
9 5.12 4.26 3.86 3.63 3.48 3.37 3.29 3.23 3.18 0.1
10 4.96 4.10 3.71 3.48 3.33 3.22 3.14 3.07 3.02 0.0 F
11 4.84 3.98 3.59 3.36 3.20 3.09 3.01 2.95 2.90
0 1 2 3 4 5
12 4.75 3.89 3.49 3.26 3.11 3.00 2.91 2.85 2.80
13 4.67 3.81 3.41 3.18 3.03 2.92 2.83 3.01 2.77 2.71
14 4.60 3.74 3.34 3.11 2.96 2.85 2.76 2.70 2.65 F0.05=3.01
15 4.54 3.68 3.29 3.06 2.90 2.79 2.71 2.64 2.59
0 .4
F(6,9) =3.37
f( F )
0 .3
0.05 The corresponding left-hand critical
0 .2
point is given by:
0 .1
1 1
0.2439
0 .0
F 9 , 6 410
.
0 1 2 3 4 5 F
F0.95=(1/4.10)=0.2439 F0.05=3.37
Hypothesis Test for
Two Population Variance
Hypotheses
H 0 : s 12 s 22 H 0 : s 12 s 22
H a : s 12 s 22 Ha : s12 s 22
Test Statistic
2
s
F 1
s22
Please read pages 378 to 381, from the text to derive left tail critical value for further details
Hypothesis Test for
Two Population Variance
Rejection Rule: one-tail (right tail) test
Reject H0 if F > F ;
where the value of F is based on an F distribution with n1 - 1
(numerator) and n2 - 1 (denominator) d.f.
Population1 : Before
n = 25 2
1 2 2
H 0: s s
s 2 9.3 1 21
1
2 2
Population 2 : After H1: s s
n = 24 1 2
2
s2
s 2 3.0 1 9.3
F 3.1
2 F
n1 1, n 2 1 24 ,23 s2 3.0
2
0.05
F 2.01
24,23 H 0 may be rejected at a 1% level of significance.
0.01
F 2.70
24,23
Example 8-9: Solution
Distribution with 24 and 23 Degrees of Freedom
Since the value of the test
0.7
0.6
statistic is above the critical
0.5 point, even for a level of
0.4
f(F )
0.3
significance as small as 0.01,
0.2 the null hypothesis may be
0.1
0.0 F
rejected, and we may conclude
0 1 2 3 4 5
that the variance of stock
F0.01=2.7 Test Statistic=3.1
prices is reduced after the
interception and prosecution
of inside traders.
Example 8-9: Solution Using the EXCEL
Population 1 Population 2
n = 14 n =9 2
H :s s
2
1 2 0 1 2
2 2 2 2
s 0.12 s 0.11 2 2
1 2 H :s s
1 1 2
0.05
s2
3.28 1 0.12 2
F F 119
13,8
F .
n1 1, n 2 1 s 0.11
13,8 2 2
2
0.10
F 2.50
13,8 H may not be rejected at the 10% level of significance.
0
Example 8-10: Solution
0.4
0.3
0.2
0.10 significance, we can not reject
0.1
0.0
the null hypothesis. We
0 1 2 3 4 5 F conclude the two population
F0.90=(1/2.20)=0.4545 F0.10=3.28
Test Statistic=1.19
variances are equal.
Template to test for the Difference between Two
Population Variances: Example 8-10
The number of homes sold for each model and price for the
past two years is shown below. For convenience, the price
of the home is listed as either Rs 30,00,000 or less or more
than Rs 30,00,000.
Price Colonial Log Duplex Studio
< 30 Lacs 18 6 19 12
> 30 Lacs 12 14 16 3
Hypothesis Test for
Unitech Example(Situation II)
Hypothesis 2:
If the customers preference of home is independent of its price and
style OR if the price and style are independent.
-known as Test of Independence of Attributes: Contingency Table
Analysis
Style
Price Colonial Log Duplex Studio Total
<=30 lacs 0.1364 2.2727 0.0032 1.7045 4.1169
> 30 lacs 0.1667 2.7778 0.0040 2.0833 5.0317
Total 0.3030 5.0505 0.0072 3.7879 9.1486 Chi-Square
(O11 E11)2 /E11 3 dof
= (18-16.5)2 /16.5 0.05 Alpha
Chi-Square
= 0.1364 7.815 (Critical Value)
Reject H0
CASE:
A Bipartisan Agenda for Change
Question: Should legislative pay be cut for every day the
state budget is late?
Yes No Totals
Democrat 22 14 36
Independent 10 9 19
Republican 39 6 45
Totals 71 29 100