Yes! Grapher does have ability to create a fit curve, limited to an X range of data, and get the equation for this range. Below are the steps you would need to create the plot, add the fit curve, and get the equation.

- Click the
**Graphs | Create | Basic | Scatter Plot**() command. - In the
**Open Worksheet**dialog, select the data file and click*Open*.

*Your scatter plot will look something like this.*

- Click on the
*Line/Scatter Plot 1*object in the**Object Manager**. - In the
**Property Manager**, click on the**Plot**tab. - Click the
*Add/Edit*button next to the*Fits*command. - In the
**Fits**dialog,- In the
*Available Fits*section, select*Linear, Y=B*X+A*. - Click
*Add*. - Click
*OK*.

- In the

You now have a fit curve added to the graph. But, this default fit curve uses all of the data points to create the equation of the line.

- Click on the
*Fit 1: Linear*object in the**Object Manager**. - In the
**Property Manager**, click on the**Plot**tab. - Click the next to
*Data limits*to open the*Data limits*section*.* - Uncheck the box next to the
*Use curve limits*option. - Update the
*Minimum value*and*Maximum value*. Both of these values are X values. You will want to give the program the range of the data you would like to use. For example, if you want to limit the equation to the red area on this graph, type in 40900 for*Minimum value*and 40950 for the*Maximum value*.

*The desired points to draw a line through. The drop lines displayed are shown to see the desired interval for the X values*.

- If you need to determine what the X range is based on the circled area, the simplest way to do this would be to use the
**Graphs | Digitize | Digitize**command. To do so:- Click on the
*Line/Scatter Plot 1*. - Click the
**Graphs | Digitize | Digitize**command. - In the plot window, click on the first symbol of interest.
- Click on the last symbol of interest.
- In the
**Grapher – Report**window, the X, Y values will be displayed. - To exit digitizing mode, click the
**Graphs | Digitize | Digitize**command or press ESC on your keyboard. - Type in the X values for the
*Minimum value*and the*Maximum value*.

- Click on the

- After changing the fit curve
*Data limits*properties, your fit curve will be reduced to the area highlighted by the red ellipse.

*The fit curve is displayed through the desired data points. *

- If you want the curve to extend the full length of the graph, but be based on only the selected data points:
- Click on the
*Fit 1: Linear*. - In the
**Property Manager**,click on the**Plot**tab. - Click the next to the
*Plot interval*to open the*Plot interval*section. - Next to the
*Plot limits*option, click*Fitted data limits*and select*Axis limits*from the list. The curve extends to the entire X axis range. - Alternatively, you can change the
*Plot Limits*to*Custom*and type the*First X*and*Last X*values. The fit curve will then be extended to these X values.

- Click on the

- Finally, to get the equation of the line:

- Click the
*Fit 1: Linear*plot. - In the
**Property Manager**, click on the**Plot**tab. - Click the next to
*Statistics*to open the*Statistics*section. - Click the button next to the
*Clipboard, Report,*or*Insert statistics*commands. Clicking on the*Copy*button next to the*Clipboard*command copies the information to the Windows clipboard for pasting into other programs. Clicking on the*Display*button next to the*Report*command opens a small text window in Grapher with the fit curve information. Clicking on the*Insert*button next to the*Insert statistics*command allows you to click on the Grapher plot window and have the fit curve information displayed next to the graph in an editable text object.

- Click the

*The fit results are displayed using the *Insert *button. *

*Updated July 7, 2016*

## 0 Comments