What is formed in at least 2 points?

A line of best fit is a straight line that is the best approximation of the given set of data.

It is used to study the nature of the relation between two variables. (We're only considering the two-dimensional case, here.)

A line of best fit can be roughly determined using an eyeball method by drawing a straight line on a scatter plot so that the number of points above the line and below the line is about equal (and the line passes through as many points as possible).

A more accurate way of finding the line of best fit is the least square method .

Use the following steps to find the equation of line of best fit for a set of ordered pairs ( x 1 , y 1 ) , ( x 2 , y 2 ) , ... ( x n , y n ) .

Step 1: Calculate the mean of the x -values and the mean of the y -values.

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

Step 2: The following formula gives the slope of the line of best fit:

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

Step 3: Compute the y -intercept of the line by using the formula:

b = Y ¯ − m X ¯

Step 4: Use the slope m and the y -intercept b to form the equation of the line.

Example:

Use the least square method to determine the equation of line of best fit for the data. Then 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 points on a coordinate plane .

What is formed in at least 2 points?

Calculate the means of the x -values and 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 i − X ¯ , y i − Y ¯ , ( x i − X ¯ ) ( y i − Y ¯ ) , and ( x i − X ¯ ) 2 for each i .

i x i y i x i − X ¯ y i − Y ¯ ( x i − X ¯ ) ( y i − Y ¯ ) ( x i − 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
∑ i = 1 n ( x i − X ¯ ) ( y i − Y ¯ ) = − 131 ∑ i = 1 n ( x i − X ¯ ) 2 = 118.4

Calculate the slope.

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

Calculate the y -intercept.

Use the formula to compute the y -intercept.

b = Y ¯ − m X ¯       = 7 − ( − 1.1 × 6.4 )         = 7 + 7.04         ≈ 14.0

Use the slope and y -intercept to form the equation of the line of best fit.

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

Therefore, the equation is y = − 1.1 x + 14.0 .

Draw the line on the scatter plot.

What is formed in at least 2 points?

Skip to content

This transaction will be unavailable from 1am to 11am on Sunday 30 October due to planned maintenance. We apologise for any inconvenience caused.

If you have an unrestricted NSW Driver Licence and you've received a notice of suspension due to excessive demerit points, you may be eligible to elect a 12-month good behaviour period.

You must apply to elect a good behaviour period before your suspension is due to begin, and once you've applied, you can't withdraw your election.

If you've been notified that you're required to pass a driver knowledge test, your licence will be suspended until you pass the test.

You can apply for a good behaviour period online if there are at least 2 business days left before your suspension is due to begin. If there are fewer than 2 business days remaining, visit a service centre or motor registry with your driver licence and your notice of suspension letter.

  • the suspension period hasn't started
  • your NSW Driver Licence is unrestricted.

You can apply online if your notice of suspension letter states that you're eligible to apply online.

  • a MyServiceNSW Account (optional)
  • your NSW driver licence details
  • your notice of suspension.

  1. Select the 'Apply online' button.
  2. Log in, or create your MyServiceNSW Account, or continue as a guest. Enter your NSW driver licence details if you're creating a MyServiceNSW Account.
  3. Check your details, then enter the notice of suspension letter identification number (found at the top left corner of the notice).
  4. Read and accept the declaration and the Terms and Conditions.
  5. Select 'Submit'.
  6. If your election is successful, you'll be issued a digital receipt. Print, save or email yourself this receipt, and keep it in a safe place until your formal letter of confirmation arrives in the mail within 14 business days.

  • If you accumulate 2 or more demerit points while serving a good behaviour period, your licence will be suspended for double the original suspension period.
  • If you choose to elect a good behaviour period, you must apply before the suspension begins. If the election is not made before the required date, then the licence suspension will be enforced.
  • Once your suspension period has begun, the notice of suspension cannot be reissued with a new date. You won't be able to change a suspension to a good behaviour period.
  • Electing the good behaviour option is not available if you hold a provisional or learner licence, or you're already serving a good behaviour period.

Last updated: 26 October 2022