Chapter 4 notes

Chapter 4 notes - Chapter 4 Describing Relationships...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
Chapter 4: Describing Relationships Between Variables Section 4.1: Fitting a Line by Least Squares Suppose that we have two variables x and y and that we wish to describe the relationship between them. In this section, we will find the best linear fit of y versus x . Linear equation: y = β 0 + 1 x , where 0 and 1 are unknown population parameters The goal is to find estimates b 0 and b 1 for the parameters 0 and 1 . Example (to be used throughout this section) : Eight batches of plastic are made and from each batch one test item is molded and its hardness y is measured at time x . The following are the 8 measurements: Time, x 32 72 64 48 16 40 80 56 Hardness, y 230 323 298 255 199 248 359 305 When looking for a relationship between two variables, a first step is to look at a scatterplot. This will allow us to determine if a linear relationship seems to be appropriate for the variables. By looking at this scatterplot we see that there appears to be a strong positive linear relationship between x and y . How do we find an equation for the line that best fits to this data? 1
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Least squares principle We will fit a line given by y = b 0 + b 1 x , where b 0 and b 1 are estimates for the parameters β 0 and 1 . Note that a straight line will not pass perfectly through every one of our data points. Thus, if we plug a data value x i into the equation y = b 0 + b 1 x , the value we get for y i will not be exactly our data value y i . The idea of fitting a line using least squares is to minimize the squared distances from the actual data value, y i , and the value given by our equation, y i . Thus, we wish to minimize ( ) y y i i i n - = 2 1 The value y i is called the observed value, while the value y i is called the fitted or predicted value. To minimize ( ) y y i i i n - = 2 1 : Plugging y i = b 0 + b 1 x i into the equation yields ( ( ) ) y b b x i i i n - + = 0 1 2 1 . Taking partial derivatives of this with respect to both b 0 and b 1 gives us what are called the Normal Equations: n b b x y i i n i i n 0 1 1 1 + = = = ∑ ∑ b x b x x y i i n i i n i i i n 0 1 1 2 1 1 + = = = = ∑ ∑ ∑ Solving these equations (details omitted) for b 0 and b 1 yields the following: b x x y y x x i i i n i i n 1 1 2 1 = - - - = = ( ) ( ) ( ) and b y b x 0 1 = - Finding the estimates for our example and interpreting them in terms of the problem : 2
Background image of page 2
Once we have an equation for the fitted line, we can use it to find a predicted/fitted value, y , for a value of x . We must, however, be careful to not extrapolate beyond our data set. Extrapolation is when a value of x beyond the range of our actual x observations is used to find a predicted y . This is a problem because the fitted line was only based on our
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 4
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 03/26/2008 for the course STAT 105 taught by Professor Bingham during the Spring '08 term at Iowa State.

Page1 / 9

Chapter 4 notes - Chapter 4 Describing Relationships...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online