Professional Documents
Culture Documents
BBADM 221 Unit 10 - With Notes
BBADM 221 Unit 10 - With Notes
BBADM 221 Unit 10 - With Notes
Week 10
ANOVA (Analysis of Variance)
2
ANOVA
Example:
• An experiment to study the effects of five different brands of
gasoline on car engine efficiency.
• A consumer looking for a new car might compare the average
gas mileage of seven car models.
• A professor wishes to study the effect of four different teaching
techniques on mathematics proficiency.
3
ANOVA
The characteristic that differentiates the treatments from one
another is called the factor of the study. The different
treatments is called the levels of the factor. Here, we only
consider one factor.
Example:
• An experiment to study the effects of five different brands of gasoline
on car engine efficiency.
Factor: Gasoline brand Treatments: The 5 different
brands
• A consumer looking for a new car might compare the average gas
mileage of seven car models.
Factor: Car model Treatments: The 7
car models
• A professor wishes to study the effect of four different teaching
techniques on mathematics proficiency.
Factor: Teaching technique Treatments: The 4 different
techniques
4
ANOVA
One-way ANOVA
(Single-factor ANOVA)
H0: 1 2 k
Ha: At least one i is different from others
7
ANOVA
Data are typically put into a table for easy referencing by
computer software. The table is called ANOVA table.
MS(Error)
Error (Within
SS(Error) n–k SS(Error)
Treatments)
nk
Total
9
ANOVA
Number of treatments: k = Total number of data: n =
Source of Variation Sum of Squares Degrees of Freedom Mean Square F
Total
ANOVA table
Source of Variation Sum of Squares Degrees of Freedom Mean Square F
Between Treatments 2.2458 2 1.1229 0.3769
Error (Within Treatments) 20.8542 7 2.9792
Total 23.1 9
12
ANOVA
Hypothesis Testing:
Source of Variation Sum of Squares Degrees of Freedom Mean Square F
Between Treatments 2.2458 2 1.1229 0.3769
Error (Within Treatments) 20.8542 7 2.9792
Total 23.1 9
F50,50
F-distribution
F10,90
F3,5
F90,10
13
ANOVA
Hypothesis Testing:
Source of Variation Sum of Squares Degrees of Freedom Mean Square F
Between Treatments 2.2458 2 (df1) 1.1229 0.3769
Error (Within Treatments) 20.8542 7 (df2) 2.9792
Total 23.1 9
Critical value
Fdf1 ,df2 F2,7 4.7375
Test Statistic
Fc 0.3769
14
ANOVA
Hypothesis Testing:
Reject H0 if (Test Statistic > Critical value)
Do not reject H0 if (Test Statistic Critical
value)
4 Fc F4,10 Reject H0
5 Conclusion: Reject H0 at a 5% level of significance.
There is sufficient evidence that at least one treatment
has a different mean.
18
ANOVA
Example:
In a completely randomized experimental design, 7 experimental
units were used for each of the 4 levels of the factor:
Between Treatments
Complete the ANOVA table and test the hypothesis that the
population treatment means are all the same, at 0.05 .
19
ANOVA
Source of Variation Sum of Squares Degrees of Freedom Mean Square F
Between Treatments 14,301 3 4,767 4.767
Error (Within Treatments) 24,000 24 1,000
Total 38,301 27
4 Fc F3,20 Reject H0
5 Conclusion: Reject H0 at a 5% level of significance.
There is sufficient evidence that at least one factor has a
different mean.
20
Unit 11
Linear Regression
21
Linear Regression
Linear equation: y mx b
slope y-intercept
y 2x 1 Slope = 2
Y-intercept = –1
y-intercept
24
Linear Regression
Mathematics Score
25
Linear Regression
Example: The exam scores of a class of 9 students in
Mathematics ( X ) and in Statistics ( Y ) are shown
below:
Math Score (X) 80 58 92 60 75 63 93 76 78
Stat Score (Y) 78 64 96 62 78 65 90 61 82
Statistics
Score
Mathematics Score
26
Linear Regression
We want to determine the equation of the regression line
that best-fits the data.
Statistics Statistics
Score Score
Statistics Statistics
Score Score
Statistics
Score
Mathematics Score
28
Linear Regression
Equation of the regression line:
df SS
Regression 1 1004.483
Residual 7 301.517
Total 8 1306
Y 9.450 0.872 X
Statistics
Score
Mathematics Score
29
Linear Regression
For example:
Score in Math Estimated score in Stat
61 9.450 +
0.872 61 = 62.42
73 9.450 +
0.872 73 = 73.11
91 9.450 +
30
Linear Regression
df SS
Regression 1 1004.483
Residual 7 301.517
Total 8 1306
Which p-value?
33
Linear Regression
df SS
Regression 1 1004.483
Residual 7 301.517
Total 8 1306
The p-value for Math Score is 0.001 < the level of significance
Reject H0 The regression relationship is significant.
34
Linear Regression
Coefficient of Determination, R2
SS (Regression)
R
2
(decimal percent)
SS (Total)
1004.483
R
2
0.7691 76.91%
1306
df SS
Regression 1 1305.68
Residual 9 81.96
Total 10 1387.64
What is the estimated regression equation that relates the exam score in
accounting (Y) to the score in mathematics (X)?
What is the estimated regression equation that relates the exam score in
accounting (Y) to the score in mathematics (X)?
Y 24.13 0.759 X
Acc.Score 24.13 0.759 (MathScore)
What is the estimated exam score in accounting if a student got a score of
80 in mathematics?
1305.68
R
2
0.9409 94.09%
1387.64
94.09% of the variability of the exam score in
accounting can be explained by the linear
relationship with the exam score in mathematics.
43
Linear Regression
Coefficient of determination
1305.68
R2
1387.64
df SS 0.9409 94.09%
Regression 1 1305.68
Residual 9 81.96
Total 10 1387.64
df SS
Regression 1 186952
Residual 13 99236
Total 14 286188
Y 78.56 0.066 X
Amt.Purchase 78.58 0.066 (Salary)
47
Linear Regression
df SS
Regression 1 186952
Residual 13 99236
Total 14 286188
186952
R
2
0.6532 65.32%
286188
65.32% of the variability of the amount
purchased can be explained by the linear
relationship with the customer’s monthly salary.
51