Professional Documents
Culture Documents
The best line will be one that is “closest” to the points on the scatterplot. In
other words, the best line is one that minimises the total distance between
itself and all the observed data points.
So based on this, the line on the right is better than the line on the left in describing
the relationship between X and Y. ***infinite number of lines***
4
y = mx + b
s xy
where the slope, b1 2
s x
We can then define the error to be the difference between the coordinates and
the prediction line.
When we square those error lines, we are literally making squares from those
lines. We can visualize this as...
So we want to find the regression line that minimizes the sum of the areas of
these error squares. For this regression line, the sum of the areas of the
squares would look like this...
9
Let`s determine the best-fitted line for following data:
s xy
Least Squares Method b1 2
b0 y b1 x
s x
10
s xy
Least Squares Method b1 2
b0 y b1 x
s x
11
s xy
Least Squares Method b1 2
b0 y b1 x
s x
12
s xy
Least Squares Method b1 2
b0 y b1 x
s x
13
s xy
Least Squares Method b1 2
b0 y b1 x
s x
s xy
Least Squares Method b1 2
b0 y b1 x
s x
x x
2
s 2
i
n 1
15
s xy
Least Squares Method b1 2
b0 y b1 x
s x
16
s xy
Least Squares Method b1 2
b0 y b1 x
s x
17
s xy
Least Squares Method b1 2
b0 y b1 x
s x
18
s xy
Least Squares Method b1 2
b0 y b1 x
s x
19
s xy
Least Squares Method b1 2
b0 y b1 x
s x
20
s xy
Least Squares Method b1 2
b0 y b1 x
s x
21
s xy
Least Squares Method b1 2
b0 y b1 x
s x
x x
2
s 2
i
n 1
22
s xy
Least Squares Method b1 2
b0 y b1 x
s x
x x
2
s 2
i
n 1
23
s xy
Least Squares Method b1 2
b0 y b1 x
s x
x x
2
s 2
i
n 1
24
s xy
Least Squares Method b1 2
b0 y b1 x
s x
x x
2
s 2
i
n 1
25
s xy
Least Squares Method b1 2
b0 y b1 x
s x
x x
2
s 2
i
n 1
26
s xy
Least Squares Method b1 2
b0 y b1 x
s x
27
What line?
ˆi
Interpretation of the b0, b1, y 9.95 2.25 xi
In a fixed and variable costs model:
ˆi
Interpretation of the b0, b1, y 9.95 2.25 xi
A simple example of a linear equation
A company has fixed costs of $7,000 for plant and equipment and
variable costs of $600 for each unit of output.
ˆi
Interpretation of the b0, b1, y 9.95 2.25 xi
b1, slope, always has the same sign as r, the correlation
coefficient — but they measure different things!
Coefficient of Determination
Coefficient of Determination