To find the equation of the linear function that best fits the given data using linear regression, we will use the least squares method. The equation of the line is generally expressed in the form \( y = mx + b \), where \( m \) is the slope and \( b \) is the y-intercept.
Given the data points:
\[ \begin{align*} x & : 1, 2, 3, 4, 5, 6 \ y & : 73, 95, 115, 130, 155, 182 \ \end{align*} \]
- Calculate the means of x and y:
\[ \bar{x} = \frac{1 + 2 + 3 + 4 + 5 + 6}{6} = \frac{21}{6} = 3.5 \]
\[ \bar{y} = \frac{73 + 95 + 115 + 130 + 155 + 182}{6} = \frac{750}{6} = 125 \]
- Calculate the slope \( m \):
The formula for the slope \( m \) is:
\[ m = \frac{\sum{(x_i - \bar{x})(y_i - \bar{y})}}{\sum{(x_i - \bar{x})^2}} \]
First, we need to calculate the components for the summations.
\[ \begin{align*} (x_i - \bar{x}) & : \ 1 - 3.5 & = -2.5 \ 2 - 3.5 & = -1.5 \ 3 - 3.5 & = -0.5 \ 4 - 3.5 & = 0.5 \ 5 - 3.5 & = 1.5 \ 6 - 3.5 & = 2.5 \ \end{align*} \]
\[ (y_i - \bar{y}) & : \ 73 - 125 & = -52 \ 95 - 125 & = -30 \ 115 - 125 & = -10 \ 130 - 125 & = 5 \ 155 - 125 & = 30 \ 182 - 125 & = 57 \ \end{align*} \]
Now calculate \( (x_i - \bar{x})(y_i - \bar{y}) \) and \( (x_i - \bar{x})^2 \):
\[ \begin{align*} \sum{(x_i - \bar{x})(y_i - \bar{y})} & = (-2.5)(-52) + (-1.5)(-30) + (-0.5)(-10) + (0.5)(5) + (1.5)(30) + (2.5)(57) \ & = 130 + 45 + 5 + 2.5 + 45 + 142.5 \ & = 370 \ \end{align*} \]
\[ \begin{align*} \sum{(x_i - \bar{x})^2} & = (-2.5)^2 + (-1.5)^2 + (-0.5)^2 + (0.5)^2 + (1.5)^2 + (2.5)^2 \ & = 6.25 + 2.25 + 0.25 + 0.25 + 2.25 + 6.25 \ & = 17.5 \ \end{align*} \]
Now we can calculate \( m \):
\[ m = \frac{370}{17.5} \approx 21.14 \]
- Calculate the y-intercept \( b \):
Using the formula:
\[ b = \bar{y} - m \bar{x} \]
\[ b = 125 - (21.14)(3.5) = 125 - 73.99 \approx 51.01 \]
- Final equation:
Now we can write the equation of the linear regression line:
\[ y = 21.14x + 51.01 \]
After rounding to two decimal places, the final equation is:
\[ y = 21.14x + 51.01 \]