8
Regression •To be able to calculate the regression line of y on x •To be able to interpret the equation of the regression line By the end of the lesson you should be a ble to answer this regression exam quest ion

Regression

  • Upload
    orien

  • View
    44

  • Download
    2

Embed Size (px)

DESCRIPTION

Regression. To be able to calculate the regression line of y on x To be able to interpret the equation of the regression line. By the end of the lesson you should be able to answer this regression exam question. The meaning of the regression line. - PowerPoint PPT Presentation

Citation preview

Page 1: Regression

Regression

•To be able to calculate the regression line of y on x

•To be able to interpret the equation of the regression line

By the end of the lesson you should be able to answer this regression exam question

Page 2: Regression

The meaning of the regression line

Rather than draw a line a best fit by eye you can calculate and plot accurately a line that minimises the distance between the data plotted and the line.

Carbon percentages against melting point

y = -4.0476x + 36.214

0

5

10

15

20

25

30

35

40

0 1 2 3 4 5 6 7 8 9

Carbon percentage

Meltin

g p

oin

t

y = a + bxa is the value of the melting point when carbon is 0%b is the rate at which the melting point reduces as the carbon percentage increases

The vertical distance between the points and the line of best fit are called residuals (red lines)This is why the regression line is sometimes called the least squares regression line

Page 3: Regression

The meaning of the regression line

The x axis shows the independent (or explanatory) variable. It is set independently of the other variable

Carbon percentages against melting point

y = -4.0476x + 36.214

0

5

10

15

20

25

30

35

40

0 1 2 3 4 5 6 7 8 9

Carbon percentage

Meltin

g p

oin

t

The y axis shows the dependent (or response) variable. These variables are determined by the x values

Page 4: Regression

Important formulaeSxx = Σx² - (Σx)² n

Sxy = Σxy - ΣxΣy n

b = Sxy Sxx

a = y - bx

Regression line equationy = a + bx

Page 5: Regression

ExampleThe results from an experiment in which different masses were placed on a spring and the resulting length of the spring measured, are shown below

Mass, x (kg) 20 40 60 80 100

Length, y (cm) 48 55.1 56.3 61.2 68

Σx = 300, Σx²=22000, x = 60, Σxy = 18238, Σy² = 16879.14, Σy = 288.6, y = 57.72

a) Calculate Sxx and Sxyb) Calculate the regression line of y on xc) Calculate the length of the spring when a mass of 50kg is

addedd) Calculate the length of the spring when a mass of 140kg is

added. Give a reason why this may or may not be a reliable answer.

Page 6: Regression

Mass, x (kg) 20 40 60 80 100

Length, y (cm) 48 55.1 56.3 61.2 68

Σx = 300, Σx²=22000, x = 60, Σxy = 18238, Σy² = 16879.14, Σy = 288.6, y = 57.72

a) Calculate Sxx and SxySxx = 22000 - 300² = 4000 5Sxy = 18238 – 300x288.6 = 922 5

b) Calculate the regression line of y on xb = Sxy = 922 = 0.2305 Sxx 4000

a = y – bxa = 57.72 – 0.2305 x 60 = 43.89

y = 43.89 + 0.2305x

Page 7: Regression

c) Calculate the length of the spring when a mass of 50kg is added

d) Calculate the length of the spring when a mass of 140kg is added. Give a reason why this is or is not a reliable answer

y = 43.89 + 0.2305xc) Y = 43.39 + 0.2305x50 = 54.915cm

d) Y = 43.39 + 0.2305 x 140 = 75.66cmThis may not a reliable answer as it has been calculated using

extrapolation. It could be unreliable140kg is outside the range of data given and used to calculate the regression line.

Page 8: Regression

Plenary

Can you now answer this mathsnet exam question?