A heat of ideal fit is a straight line that is the finest approximation that the given set of data.

it is offered to research the nature of the relation in between two variables. (We"re only considering the two-dimensional case, here.)

A line of finest fit have the right to be approximately determined making use of an eyeball an approach by illustration a directly line on a scatter plot so that the number of points above the line and also below the line is about equal (and the heat passes v as countless points together possible).

A more accurate way of detect the line of best fit is the least square technique .

usage the adhering to steps to find the equation of heat of finest fit for a collection of ordered pairs ( x 1 , y 1 ) , ( x 2 , y 2 ) , ... ( x n , y n ) .

action 1: calculation the median of the x -values and the average of the y -values.

X ¯ = ∑ ns = 1 n x ns n Y ¯ = ∑ i = 1 n y ns n

action 2: The adhering to formula provides the slope of the line of finest fit:

m = ∑ ns = 1 n ( x ns − X ¯ ) ( y ns − Y ¯ ) ∑ ns = 1 n ( x i − X ¯ ) 2

step 3: Compute the y -intercept the the heat by utilizing the formula:

b = Y ¯ − m X ¯

action 4: usage the steep m and the y -intercept b to form the equation of the line.




You are watching: Method of selected points

Example:

usage the least square an approach to recognize the equation of line of best fit for the data. Climate plot the line.
x 8 2 11 6 5 4 12 9 6 1
y 3 10 3 6 8 12 1 4 9 14


Solution: Plot the clues on a coordinate plane .

*

calculate the means of the x -values and also the y -values.

X ¯ = 8   +   2   +   11   +   6   +   5   +   4   +   12   +   9   +   6   +   1 10 = 6.4 Y ¯ = 3   +   10   +   3   +   6   +   8   +   12   +   1   +   4   +   9   +   14 10 = 7

now calculate x ns − X ¯ , y i − Y ¯ , ( x i − X ¯ ) ( y ns − Y ¯ ) , and also ( x i − X ¯ ) 2 for each i .

ns x ns y i x i − X ¯ y i − Y ¯ ( x i − X ¯ ) ( y ns − Y ¯ ) ( x ns − X ¯ ) 2
1 8 3 1.6 − 4 − 6.4 2.56
2 2 10 − 4.4 3 − 13.2 19.36
3 11 3 4.6 − 4 − 18.4 21.16
4 6 6 − 0.4 − 1 0.4 0.16
5 5 8 − 1.4 1 − 1.4 1.96
6 4 12 − 2.4 5 − 12 5.76
7 12 1 5.6 − 6 − 33.6 31.36
8 9 4 2.6 − 3 − 7.8 6.76
9 6 9 − 0.4 2 − 0.8 0.16
10 1 14 − 5.4 7 − 37.8 29.16
∑ ns = 1 n ( x ns − X ¯ ) ( y i − Y ¯ ) = − 131 ∑ i = 1 n ( x ns − X ¯ ) 2 = 118.4

calculation the slope.

m = ∑ i = 1 n ( x i − X ¯ ) ( y i − Y ¯ ) ∑ ns = 1 n ( x i − X ¯ ) 2 = − 131 118.4 ≈ − 1.1

calculation the y -intercept.

usage the formula to compute the y -intercept. b = Y ¯ − m X ¯       = 7 − ( − 1.1 × 6.4 )         = 7 + 7.04         ≈ 14.0

usage the slope and also y -intercept to kind the equation of the line of finest fit.

See more: Black Ink Crew Chicago Season 4 Episode 13, Black Ink Crew Chicago

The slope of the line is − 1.1 and the y -intercept is 14.0 .