Linear Regression


Linear regression analysis calculates a straight line that best represents the relationship between two variables for which measurements are made in ordered pairs.


Calculating Slope and Intercept


To calculate the slope (m) and the y-intercept (b) of the representative line, press
[ STAT ]{ m-b }.
  1. The slope appears in the display.
  2. The y-intercept is stored in the t-register. Press [ x~t ] to display the number.
The representative line is:

y = mx + b

Calculating the Correlation Coefficient

To calculate the correlation coefficient, press [ STAT ]{ r }. The correlation coefficient is a measure of how well the representative line fits the two sets of data values.

When the
| r | is close to 1, most of the data is on or very near the line, in which case the line is highly representative of the data. However, the validity of the line diminishes as | r | decreases.

Calculating a Predicated Value

If | r | is close to 1, you can use the equation of the line to make valid predications about additional data.
  1. To predict a y value, enter an x value and press { y' }.
  2. To predict an x value, enter a y value and press [ INV ]{ y' }.

Example

A life insurance company has found that the volume of sales varies according to the number of salespeople employed, as shown below.

Number of salespeople (x)= 7, 12, 4, 5, 11, 9


Sales in thousands $/mo. (y)= 99, 152, 81, 98, 145, 112


Perform a linear regression analysis and predict the number of salespeople needed to produce $115,000 in monthly sales. Then, estimate the amount of sales that should be generated by 10 salespeople.

Procedure

Press

Display

Clear display[ CLEAR ]D_McSSNB
Clear registers and select 2-variable[ STAT ]
{ CLR } { CS2 }
D_aIXgn4
Begin data entry7 [ x~t ]
99 [ ∑+ ]
D_bToF5I
12 [ x~t ]
152 [ ∑+ ]
D_eJssgL
4 [ x~t ]
81 [ ∑+ ]
D_CiPql8
5 [ x~t ]
98 [ ∑+ ]
D_ThPOaZ
11 [ x~t ]
145 [ ∑+ ]
D_S2HZBc
9 [ x~t ]
112 [ ∑+ ]
D_xvdFWP
Slope (m){ --> }{ m-b }D_q4rG6s
y-intercept (b)[ x~t ]D_ETq9o4
Correlation coeff.{ r }D_oOmULc
Projected sales for 10 people10
{ y' }
D_eE9le3
Number of people needed for $115,000115
[ INV ]{ y' }
D_1Q21ue
The equation 8.42x + 47.12 describes the representative line, with a correlation coefficient of 0.96.

Back