2.8 Simple Fit

Summary

This Simple Fit app provides a convenient way to perform curve fitting. With the data plotted, simply open the tool, type the desired equation, specify initial parameters and generate your report. You do not need to even save or create a fitting function.

Linear Fit

  1. Download sample file Simple_Fit_App.zip. Open the Simple Fit App.opju project in the zip file.
  2. Select 1. Linear folder in the Project Explorer. Activate Graph1 window and then click on Simple Fit icon Simple Fit icon.png from the Apps panel.
    Simple Fit Linear 01.png
  3. Select Linear in the Simple Fit dialog. Check the 95% Confidence Band and 95% Prediction Band . Then click Report button.
    Simple Fit Linear 02.png
  4. A report table is added to the graph and a new report sheet is added to the Workbook.
    Simple Fit Linear 03.png

Polynomial Fit

  1. Select 2. Polynomial folder in the Project Explorer of Simple Fit App.opju. Activate Polynomial graph and then click on Simple Fit icon Simple Fit icon.png from the Apps panel.
    Simple Fit Polynomial 01.png
  2. Select Polynomial in the Simple Fit dialog. Click Report button.
    Simple Fit Polynomial 02.png
  3. A report table is added to the graph and a new report sheet is added to the Workbook.
    Simple Fit Polynomial 03.png

Nonlinear Fit

Example 1

  1. Select 3. NLFit folder in the Project Explorer of Simple Fit App.opju. Activate Graph3 window. This is a Gaussian curve with error bars. While the Simple Fit app provides a few built-in Gaussian functions that can be used for fitting, in this example we will show how to define a new function within the app.
    Simple Fit NLFit 01.png
  2. Click on Simple Fit icon Simple Fit icon.png from the Apps panel.
  3. Select Nonlinear in the Simple Fit dialog. Input the defined equation in the dialog.
    y0 + A/(w*sqrt(pi/2))*exp((-2*(x-xc)^2)/w^2)

    Then define the values for the parameters: A=90, xc=25.

    Simple Fit NLFit 02.png
  4. Click on Fit button and the fit converges.
    Simple Fit NLFit 03.png
  5. Click on Save As... button, then you can save this new fitting function in the User File Folder and to use it in the future.
    Simple Fit NLFit 04.png
  6. For output table, you also can change the output value. Right-click on the Adj. R-Sqr, select Reduced Chi-Sqr in the drop-down list.
    Simple Fit NLFit 05.png
  7. Click Report button. A report table is added to the graph and a new report sheet is added to the Workbook.
    Simple Fit NLFit 06.png

Example 2

  1. Activate Graph4 window. In this sample, there are 3 curves, and we will use an existing function to fit all curves in the graph.
    Simple Fit NLFit 07.png
  2. Click on Simple Fit icon Simple Fit icon.png from the Apps panel.
  3. Select Nonlinear in the Simple Fit dialog. Check Fit All Curves in the Graph and Use Existing Function check box. In the Origin Basic Function group, select ExpDec2 as fitting function. Click Fit button. The fitting is converged.
    Simple Fit NLFit 08.png
  4. Click Report button. A report table is added to the graph and a new report sheet is added to the Workbook.
    Simple Fit NLFit 09.png