Guide to fit curves in Grapher

Whether you're applying predefined fit curves, creating custom fits, or fine-tuning your analysis by applying fits to data subsets, this guide will empower you to extract valuable insights from your data. We'll also cover how to display and edit fit statistics, add fit curves to class variables in scatter plots, and efficiently export fit curve data to further enrich your analytical workflow

Table of Contents

Apply a predefined fit curve to a line/scatter plot

Create a custom fit curve

Apply a fit to a data subset

Display the fit statistics

Edit the fit curve statistics display

Add a fit curve to a class variable in a class scatter plot

Export fit curve data to a data file

 

Apply a predefined fit curve to a line/scatter plot

  1. Click on the Line/Scatter Plot in the Object Manager to select it.
  2. Click Graph Tools | Add to graph | Fit Curve and select the type of pre-defined fit curve you want

Create a custom fit curve

To add a custom fit curve to your Grapher plot, follow the steps below.

  1. Select the Plot you wish to add the fit curve to in the Object Manager.
  2. Click Graph Tools | Add to Graph |Custom Fit
    14_-_Grapher_Add_Custom_Fit_Menu_Button.png
  3. In the Add Custom Fit dialog, specify your custom fit equation and parameters, and click OK.12_-_Grapher_Add_Custom_Fit_Equation_Dialog.png
    For detailed information about custom fit parameters, see the Add Custom Fit page in Grapher's help.

 

To edit any aspect of the fit curve, select the Fit curve in the Object Manager and then edit the Fit equation and Parameters on the Plot tab of the Property Manager.

Custom_Fit_Curve_Properties.png

 

Apply a fit to a data subset

  1. Click on the Line/Scatter Plot in the Object Manager to select it.
  2. Click Graph Tools | Add to Graph | Fit Curve | Linear Fit or your desired fit type.
    18_-_Grapher_Graph_Tools_Add_Fit_Curve.png
  3. Click on the Fit object in the Object Manager to select it.
  4. In the Property Manager, click on the Plot tab.
  5. In the Fitted Plot section, uncheck the box next to Apply fit to entire plot.
    20_-_Grapher_Property_Manager_Plot_Tab_Apply_to_Fit.png
  6. Update the Minimum X plot value to fit (or Minimum X date/time if the values in the data file are formatted as date/time).
  7. Update the Maximum X plot value to fit (or Maximum X date/time if the values in the data file are formatted as date/time) with the x values for the data range you wish to use.

    For example, if you were to limit the equation to the area circled in red below, you would enter 40900 for Minimum X plot value to fit and 40945 for the Maximum X plot value to fit.

Area_to_fit_the_curve.png

8. After changing the fit curve Fitted Plot properties, your fit curve will be reduced area within the circle.

fit_applied_to_area_of_interest.png

 

Display the fit statistics 

  1. Click on the fit curve in the Object Manager to select it.
  2. In the Property Manager, click on the Plot tab.
  3. Expand the Statistics section, and select how you want the statistics to be displayed.

 

Edit the fit curve statistics display

Fit curve statistics inserted into your plot can be edited in the Property Manager or the Text Editor. For example, to adjust the significant digits or decimal places displayed in your fit curve statistics.

  1. In the Object Manager, click the Fit object to select it.
  2. In the Property Manager, click the Plot tab.
  3. Set the Number format field to Compact or Fixed.
  4. Set the Significant digits or Decimal places to the desired number.

Linked statistics inserted using the Insert into plot document command will automatically update. You may also edit their font properties, and rearrange and/or remove them by first selecting the text box, then applying your desired changes in the Property Manager. You can also double click the text box to open the Text Editor and customize your text.

Inserted_Linear_Fit_Statistics.png

 

Note that the significant digits adjustments will not update statistics in an open Report window, nor will it update any statistics pasted into a text object using the Copy to clipboard command.

  • To update your statistics report, close and reopen the report.
  • To update a text object, delete the existing text object and create a new one.

Add a fit curve to a class variable in a class scatter plot

You can define custom fits by adding a fit curve to one class, or to all classes in a class scatter plot. To do this, follow the steps below.

  1. In the Object Manager, select the class scatter plot you wish to add the fit curve to.
  2. Click Graph | Add to Graph | Fit Curve.
  3. In the Object Manager, select the fit curve object you just added.
  4. In the Property Manager, click the Plot tab.
  5. In the Fitted Plot section, in the Class field, either choose a specific class to fit the curve to, or select (All).

You may edit any aspect of the fit curve by selecting your curve in the Object Manager, and then editing its parameters (such as the Fit type and Plot Interval) in the Property Manager. More details on editing fit curves can be found here: Grapher Fit Curves Training Video

 

Export fit curve data to a data file

The X,Y points of a Grapher fit curve can be exported by following the steps below.

  1. Click the Fit curve in the Object Manager.
  2. Click Graph Tools | Plot Tools | Export Data.
  3. Click OK in the Export Data dialog. 

    11_-_Grapher_Export_Fit_Curve_Data_Analysis.png

  4. The graph coordinates of the fit curve are added to a new worksheet.
  5. Click File | Save As to save the results to your desired data file format.

 

Updated April 2023

Was this article helpful?
5 out of 16 found this helpful

Comments

0 comments

Please sign in to leave a comment.