Download presentation

Presentation is loading. Please wait.

Published byFredrick Hille Modified about 1 year ago

1
Copyright © 2010 Pearson Education, Inc. Slide 27 - 1

2
Copyright © 2010 Pearson Education, Inc. Slide 27 - 2 Solution: C

3
Copyright © 2010 Pearson Education, Inc. Chapter 27 Inferences for Regression

4
Copyright © 2010 Pearson Education, Inc. Slide 27 - 4 An Example: Body Fat and Waist Size Our example revolves around the relationship between % body fat and waist size (in inches). Here is a scatterplot of our data set:

5
Copyright © 2010 Pearson Education, Inc. Slide 27 - 5 Remembering Regression In regression, we want to model the relationship between two quantitative variables, one the predictor and the other the response. To do that, we imagine an idealized regression line, which assumes that the means of the distributions of the response variable fall along the line even though individual values are scattered around it. We would like to know what the regression model can tell us beyond the individuals in the study. We want to make confidence intervals and test hypotheses about the slope and intercept of the regression line.

6
Copyright © 2010 Pearson Education, Inc. Slide 27 - 6 The Population and the Sample We know better than to think that even if we knew every population value, the data would line up perfectly on a straight line. In our sample, there’s a whole distribution of %body fat for men with 38-inch waists:

7
Copyright © 2010 Pearson Education, Inc. Slide 27 - 7 The Population and the Sample (cont.) This is true at each waist size. We could depict the distribution of %body fat at different waist sizes like this:

8
Copyright © 2010 Pearson Education, Inc. Slide 27 - 8 The Population and the Sample (cont.) The model assumes that the means of the distributions of %body fat for each waist size fall along the line even though the individuals are scattered around it. The model is not a perfect description of how the variables are associated, but it may be useful. If we had all the values in the population, we could find the slope and intercept of the idealized regression line explicitly by using least squares.

9
Copyright © 2010 Pearson Education, Inc. Slide 27 - 9 The Population and the Sample (cont.) We write the idealized line with Greek letters and consider the coefficients to be parameters: 0 is the intercept and 1 is the slope. Corresponding to our fitted line of, we write Now, not all the individual y’s are at these means—some lie above the line and some below. Like all models, there are errors.

10
Copyright © 2010 Pearson Education, Inc. Slide 27 - 10 The Population and the Sample (cont.) Denote the errors by . These errors are random, of course, and can be positive or negative. When we add error to the model, we can talk about individual y’s instead of means: This equation is now true for each data point (since there is an to soak up the deviation) and gives a value of y for each x.

11
Copyright © 2010 Pearson Education, Inc. Slide 27 - 11 Assumptions and Conditions In Chapter 8 when we fit lines to data, we needed to check only the Straight Enough Condition. Now, when we want to make inferences about the coefficients of the line, we’ll have to make more assumptions (and thus check more conditions). We need to be careful about the order in which we check conditions. If an initial assumption is not true, it makes no sense to check the later ones.

12
Copyright © 2010 Pearson Education, Inc. Slide 27 - 12 Assumptions and Conditions (cont.) 1.Linearity Assumption: Straight Enough Condition: Check the scatterplot—the shape must be linear or we can’t use regression at all.

13
Copyright © 2010 Pearson Education, Inc. Slide 27 - 13 Assumptions and Conditions (cont.) 1.Linearity Assumption: If the scatterplot is straight enough, we can go on to some assumptions about the errors. If not, stop here, or consider re-expressing the data to make the scatterplot more nearly linear. Check the Quantitative Data Condition. The data must be quantitative for this to make sense.

14
Copyright © 2010 Pearson Education, Inc. Slide 27 - 14 Assumptions and Conditions (cont.) 2.Independence Assumption: Randomization Condition: the individuals are a representative sample from the population. Check the residual plot (part 1)—the residuals should appear to be randomly scattered.

15
Copyright © 2010 Pearson Education, Inc. Slide 27 - 15 Assumptions and Conditions (cont.) 3.Equal Variance Assumption: Does The Plot Thicken? Condition: Check the residual plot (part 2)—the spread of the residuals should be uniform.

16
Copyright © 2010 Pearson Education, Inc. Slide 27 - 16 Assumptions and Conditions (cont.) 4.Normal Population Assumption: Nearly Normal Condition: Check a histogram of the residuals. The distribution of the residuals should be unimodal and symmetric. Outlier Condition: Check for outliers.

17
Copyright © 2010 Pearson Education, Inc. Slide 27 - 17 Assumptions and Conditions (cont.) If all four assumptions are true, the idealized regression model would look like this: At each value of x there is a distribution of y- values that follows a Normal model, and each of these Normal models is centered on the line and has the same standard deviation.

18
Copyright © 2010 Pearson Education, Inc. Slide 27 - 18 Which Came First: the Conditions or the Residuals? There’s a catch in regression—the best way to check many of the conditions is with the residuals, but we get the residuals only after we compute the regression model. To compute the regression model, however, we should check the conditions. So we work in this order: Make a scatterplot of the data to check the Straight Enough Condition. (If the relationship isn’t straight, try re-expressing the data. Or stop.)

19
Copyright © 2010 Pearson Education, Inc. Slide 27 - 19 If the data are straight enough, fit a regression model and find the residuals, e, and predicted values,. Make a scatterplot of the residuals against x or the predicted values. This plot should have no pattern. Check in particular for any bend, any thickening (or thinning), or any outliers. If the data are measured over time, plot the residuals against time to check for evidence of patterns that might suggest they are not independent. Which Come First: the Conditions or the Residuals? (cont.)

20
Copyright © 2010 Pearson Education, Inc. Slide 27 - 20 Which Come First: the Conditions or the Residuals? (cont.) If the scatterplots look OK, then make a histogram and Normal probability plot of the residuals to check the Nearly Normal Condition. If all the conditions seem to be satisfied, go ahead with inference.

21
Copyright © 2010 Pearson Education, Inc. Slide 27 - 21 Intuition About Regression Inference Spread around the line: Less scatter around the line means the slope will be more consistent from sample to sample. The spread around the line is measured with the residual standard deviation s e. You can always find s e in the regression output, often just labeled s.

22
Copyright © 2010 Pearson Education, Inc. Slide 27 - 22 Intuition About Regression Inference (cont.) Spread around the line: Less scatter around the line means the slope will be more consistent from sample to sample.

23
Copyright © 2010 Pearson Education, Inc. Slide 27 - 23 Intuition About Regression Inference (cont.) Spread of the x’s: A large standard deviation of x provides a more stable regression.

24
Copyright © 2010 Pearson Education, Inc. Slide 27 - 24 Intuition About Regression Inference (cont.) Sample size: Having a larger sample size, n, gives more consistent estimates.

25
Copyright © 2010 Pearson Education, Inc. Slide 27 - 25 Standard Error for the Slope Three aspects of the scatterplot affect the standard error of the regression slope: spread around the line, s e spread of x values, s x sample size, n. The formula for the standard error (which you will probably never have to calculate by hand) is:

26
Copyright © 2010 Pearson Education, Inc. Slide 27 - 26 Sampling Distribution for Regression Slopes When the conditions are met, the standardized estimated regression slope follows a Student’s t-model with n – 2 degrees of freedom.

27
Copyright © 2010 Pearson Education, Inc. Slide 27 - 27 Sampling Distribution for Regression Slopes (cont.) We estimate the standard error with where: n is the number of data values s x is the ordinary standard deviation of the x- values.

28
Copyright © 2010 Pearson Education, Inc. Slide 27 - 28 What About the Intercept? The same reasoning applies for the intercept. The intercept usually isn’t interesting. Most hypothesis tests and confidence intervals for regression are about the slope.

29
Copyright © 2010 Pearson Education, Inc. Slide 27 - 29 Regression Inference A null hypothesis of a zero slope questions the entire claim of a linear relationship between the two variables—often just what we want to know. To test H 0 : 1 = 0, we find and continue as we would with any other t-test. The formula for a confidence interval for 1 is

30
Copyright © 2010 Pearson Education, Inc. Slide 27 - 30 FMin 44142.7 46142.1 47143.4 50143.6 51144 52143.4 54142.4 55143.1 57143.7 60143.4 65143.4

31
Copyright © 2010 Pearson Education, Inc. Slide 27 - 31 Example: Below are the times and temperatures for 11 of the top performances in women’s marathons during the 1990s. Let’s examine the influence of temperature on the performance of elite runners in marathons. a. Enter the temperatures in L1 and the runner’s times in L2. Check the scatterplot. Is it obviously nonlinear? b. Is the data independent, does the plot thicken? c. Is the histogram of the residuals unimodal and symmetric? (Put RESID (from List, names) as y, What do you have to do to get the residuals?) d. How many degrees of freedom are there? e. Perform a regression slope t-test. Use a two tailed option because we are interested in whether high temperatures enhance or interfere with a runner’s performance. You can store the equation in Y1 (Vars, Y-Vars, Function) f. You are given the t-value and P-value, the coefficients of the regression equation a and b, and the value of s (our sample estimate of the common standard deviation of errors around the true line), r squared and r. Find SE(b) (SE(b) = b/t. g. What is your conclusion?

32
Copyright © 2010 Pearson Education, Inc. Slide 27 - 32 Example: Create a 95% confidence interval for the slope. What is your conclusion?

Similar presentations

© 2017 SlidePlayer.com Inc.

All rights reserved.

Ads by Google