Professional Documents
Culture Documents
Week 1 2 3 4 5
Number of TV Ads 1 3 2 1 3
Number of Cars Sold 14 24 18 17 27
By looking at the scatter diagram, we can observe that there exists a strong
linear relationship between the number of TV ads (the independent variable,
explanatory variable or predictor) and the number of cars sold (the dependent
variable or response variable).
We may draw more than one straight line through the scatter diagram.
Definitions For n pairs of data (x1, y1), (x2, y2), , (xn, yn),
let
1 1
= =1 , = =1
define
=1( )( )
1 =
=1( )2
0 = 1 ()
Let yi b0 b1 xi for i = 1, 2, , n.
Theorem
n
b0 and b1 meet the least squares criterion. That is, the value of yi y i
2
i 1
STAT0302 ch9 2
Two formulae for calculation:
1
( )( ) =
=1 =1 =1 =1
2
1
( )2 = 2 ( )
=1 =1 =1
b1 20 4 5,
Interval estimation
The 100(1 )% confidence interval for 1 is
where
= =1( )2 , = =1( )2 , = =1( ) ( )
Hypothesis test
1 1,0
The test statistic is
2
2
(2)
1 1,0 1 1,0
t,n2
or 1 1,0 2
1 1,0 (2) 2
|1 1,0 |
t2,n2
1 1,0 1 1,0
2
2
(2)
2 4 114 202 7
,2 = 0.025,3 = 3.182 = 3.437
2 ( 2) 2 (5 2)42 6
1 1,0 53
= 7
= 1.852
2
6
(2) 2
Since 1.852 2.353 t0.05,3, we cannot reject H0. We cannot conclude that 1 is
greater than 3 at the 5% level of significance.
STAT0302 ch9 5
Section 9.3 Correlation Coefficients
Definition For n pairs of data
(x1, y1), (x2, y2), , (xn, yn),
Coefficient of determination = r2
STAT0302 ch9 6
Example (Reed Auto)
S xy 20
r 0.9366.
S xx S yy 4 114
0 b0 b1 x01.
STAT0302 ch9 7