Title: Simple Linear Regression
1Chapter 9
2- Ex The Kelly Blue Book provides information on
wholesale and retail prices of cars. 10
Corvettes are randomly selected between 1 and 6
years old. Their price (in hundreds of dollars)
is also computed.
This example was taken from Elementary
Statistics, 6th ed. by Neil Weiss
3- The scatter plot shows a linear relationship
between Age and Price. - What if we want to buy a Corvette thats 3.5
years old? It would be good to know
approximately what to pay.
4Correlation
- This is a way to measure how strong the linear
- relationship is between 2 numerical variables.
- is the population correlation coefficient
- is Pearsons sample correlation
- coefficient
-
5 -1 -0.8 -0.5
0.5 0.8
1
If r is in here, we have a weak linear
correlation.
If r is here, we have a moderate linear
correlation.
If r is here, we have a strong linear correlation.
If r is -1 or 1, the relationship is perfectly
linear meaning all points lie on a line.
6Circle the answers
- Whats the trend?
- downward
- flat
- upward
- Whats the correlation?
- weak
- moderate
- strong
- perfect
7- Whats the trend?
- downward
- flat
- upward
- Whats the correlation?
- weak
- moderate
- strong
- perfect
8- Whats the trend?
- downward
- flat
- upward
- Whats the correlation?
- weak
- moderate
- strong
- perfect
9- Whats the trend?
- downward
- flat
- upward
- Whats the correlation?
- weak
- moderate
- strong
- perfect
10- Functional Relationship These are relationships
that are strictly mathematical. Their
relationship is perfect. - Ex F9/5 C 32. You give C and you get F.
There is no uncertainty about this.
11The error term points out that there is something
else that plays a role in determining Y. We hope
its not too important.
The relationship between x and Y is not perfect.
12- These points are not all in a perfect straight
line. - Besides Age, what else could determine the price
of a car?
13- It looks like we have this relationship
-
But since we dont know what else influences the
Price, we dont know what this exact line is
either. We will have to estimate the line.
The overall relationship is linear. Usually you
see it as mxb.
14Method of Least Squares
- This is the method of choice when
- estimating a and ß. Estimates are found
- so as to minimize
- Call these estimates a and b.
15Prediction
- After applying Least
- Squares, we get the
- blue line. This line is
- Y -27.90Age436.60
- If we buy a 3.5 year old
- Corvette, what price
- should we expect to pay?
16Coefficient of Determination
- This is denoted and is equal to the square
- of the sample correlation coefficient ( ).
- We can partition the variation of Y into 2 parts
- Model and Error.
- tells us what percentage of this variation
the - model has accounted for.
17Example
- A random sample of 4 days is taken. The
- temperature (x) in Fahrenheit and coffee sales
(y) - in hundreds of dollars is taken.
18- For the coffee sales data, what are the
- following?
- the sample correlation
- the least squares line
- the coefficient of determination (interpret this)
- the predicted sales if the temperature is 45.
19Hypothesis Testing
- We may want to test whether or not there
- is a linear correlation. That is
- If we fail to reject the null hypothesis, we are
- concluding that there is no linear correlation
- between X and Y.
20- In other words, X is not useful in making
- predictions about Y. Since no matter what X
- is, we are basically getting back the same Y
- value.
- To test this claim, we can use Table A-6 to find
- the critical value.
21Example
- A random sample of 5 bears is taken and their
- chest size (in inches) and weight (in pounds) is
- measured. In the woods, when a bear is
- anesthetized, it will be easier to measure the
- chest size than the weight. Hopefully the chest
- size can be used to predict the weight.
22- What is the sample correlation coefficient?
- To test the claim that the population correlation
coefficient is equal to 0 at the 0.05
significance level, what is the critical value?
23- What is the conclusion for testing this claim?