Several (but not all) graph objects in ALiX provide the ability to perform fits of a limited number of model functions to a selected plot.
Graphs offer this option through a right-click menu such as the one shown below:
This menu is accessible from the plot area of the graph or the legend.
To select a plot, move the mouse to a region of the graph were the plot can be easily singled out (this might require zooming in) and right-click as close as possible to the target plot. Alternatively, right-click on the plot name in the legend area (right-clicking on the plot symbol gives access to a different menu).
The choice of models depends on the version used. Their description can be found in the Fit Models section of the ALiX Reference chapter of the manual.
After selecting a model, the program will attempt to fit it to the selected plot, and if successful, will display the result on the graph as a new plot. Note that some models can be provided guess parameters by using cursors (e.g. Two Gaussians. Three Gaussians, etc.). Check the ALiX Reference >> Curve Fitting >> Fit Models section of the manual for details of which parameter guesses can be provided.
Options controlling the number of points used to plot the fitted curve (or, in the case of a multicomponent fit, the number of plots shown) can be set in theĀ Histogram Fits tab of the Settings window. The fitted parameters and their 1-sigma uncertainty, as well as derived parameters (such as FWHM or mean) will be added to the Notebook. The Mean Squared Error (MSE) and Coefficient of Determination (R^2) will be appended to the results.
Note that only the visible part of the plot will be fitted. In other words, to exclude a section of a plot from the fit, simply make sure that the graph boundaries are chosen such that this section is not visible.
Curve fitting is not guaranteed to work (or work satisfactorily) in all circumstances. If a fit fails, no fitted plot will be added to the graph and a failure message will be added to the Notebook.
In some cases, the fit will succeed, but the quality of the fit might not be satisfactory. This can potentially be improved by changing the algorithm used to perform the fit. This is defined in the Histogram Fits tab of the Settings window. Please refer to the corresponding page of the manual for details on the different options.