Processing math: 100%

EXAMPLE 8 Least-Squares Regression of BAC on Number of Beers

Go back to the BAC-beer data in Table 6.1 (page 243). Use your calculator or spreadsheet software to verify the following:

  • The mean and standard deviation of x, number of beers consumed, are ˉx=4.8125 and sx=2.1975.
  • The mean and standard deviation of y, BAC, are ˉy=0.07375 and sy=0.04414.
  • The correlation between the number of beers and BAC is r=0.8943.

The least-squares regression line of BAC (y) on number of beers (x) has slope

m=rsysx=0.8943×0.044142.1975=0.01796

and y-intercept

b=ˉymˉx=0.07375(0.01796)(4.8125)=0.0127

The equation of the least-squares line is therefore

ˆy=0.0127+0.01796x

just as we claimed earlier.

When doing calculations like this by hand, you should carry extra decimal places in the intermediate calculations to get accurate values of the slope and intercept and not round until your final answer. Using software or a calculator with a regression function eliminates this worry.

[Leave] [Close]