Click on YouTube video below:

Desmos: Line of Best Fit from Table

For some assignments, you’ll need to create a line of best fit from table values. So, if you’re given a T-chart or X-Y chart, all you have to do is follow the video instructions to create a line of best fit.

First, you’ll want to go to Desmos.com. From there you’ll click on START GRAPHING. Then, you’ll click on the plus sign in the upper left-hand corner. From the dropdown menu, choose table. You can then copy your table values from your question/assignment onto the table from Desmos.

Next, you’ll start typing in the box below the table you just created. You’ll type Y1. It will show up as Y-sub 1. Basically, Y with a subscript of one. Now, instead of typing an equals sign, you’ll type a Tilda, ~. That’s to show an approximation, which is a line of best fit (otherwise known as a Least Squares Regression Line).

To the right of the Tilda, you’ll type mx1+b. Don’t worry. Desmos knows that you want to type x-sub-1. That’s what’s great about Desmos. It works intuitively.

In any case, once you’ve done all that, Desmos will then graph the line of best fit. You can see it as the black line approximating your inputted values. Also, they include the linear equation itself. In this case it’s shown as m=1 and b=-0.8. That translates as y=1x-0.8.

Finally, Desmos includes a valuable piece of information: R^2. That shows how accurate the line of best fit actually fits the data. In this case, it’s 0.9259. That means the line of best fit is 92.59% accurate in approximating the data.

## A few points to note:

-Usually, you’ll want a high R^2 value. It can range from 0 to 1. Anything from 0.8-0.99 is usually quite accurate, indicating a close approximation to the data values. The threshold for accuracy can vary from class to class and from question to question, but the higher, the better.

-This case was a simple one with few data values. Many LSRLs include more than a dozen points on the coordinate plane. The more points, the more complicated the approximation can be.

-We used a linear approximation. There are many more types of approximations, the most common being linear, exponential, quadratic. The more advanced your math class, the more types of approximations you should try. Typically, your choice will be the line of best fit with the highest R^2 value.

Good luck! Let me know if you have any questions.