2.3.3.3.129. NXfit

Status:

base class, extends NXprocess

Description:

Description of a fit procedure.

Symbols:

The symbols used in the schema to specify e.g. dimensions of arrays.

dimRank: Rank of the dependent and independent data arrays (for multidimensional/multivariate fit.)

Groups cited:

NXdata, NXfit_background, NXfit_function, NXpeak

Structure:

label: (optional) NX_CHAR

Human-readable label for this fit procedure.

figure_of_meritMETRIC: (optional) NX_NUMBER {units=NX_UNITLESS}

Figure-of-merit to determine the goodness of fit, i.e., how well the peak mode ...

Figure-of-merit to determine the goodness of fit, i.e., how well the peak model fits the measured observations.

This value (which is a single number) is oftenused to guide adjustments to the fitting parameters in the peak fitting process.

@metric: (optional) NX_CHAR

Metric used to determine the goodness of fit. Examples include: ...

Metric used to determine the goodness of fit. Examples include: - \(\chi^2\), the squared sum of the sigma-weighted residuals - reduced \(\chi^2\):, \(\chi^2\): per degree of freedom - \(R^2\), the coefficient of determination

data: (optional) NXdata

Input data and results of the fit.

input_dependent: (optional) NX_NUMBER (Rank: dimRank) {units=NX_ANY}

Position values along one or more data dimensions (to hold the ...

Position values along one or more data dimensions (to hold the values for the independent variable for this fit procedure).

input_independent: (optional) NX_NUMBER (Rank: dimRank) {units=NX_ANY}

Independent input axis for this fit procedure.

envelope: (optional) NX_NUMBER (Rank: dimRank) {units=NX_ANY}

Resulting envelope of applying the `global_fit_function` with its parameter ...

Resulting envelope of applying the global_fit_function with its parameter to the data stored in input_independent.

residual: (optional) NX_NUMBER (Rank: dimRank) {units=NX_ANY}

Difference between the envelope and the input_independent data to be fitted.

peakPEAK: (optional) NXpeak

One peak of the peak model. ...

One peak of the peak model. If there is no characteristic name for each peak component, is envisioned that peaks are labeled as peak_0, peak_1, and so on.

total_area: (optional) NX_NUMBER {units=NX_ANY}

Total area under the curve (can also be used for the total area minus any ...

Total area under the curve (can also be used for the total area minus any background values).

relative_sensitivity_factor: (optional) NX_NUMBER {units=NX_UNITLESS}

Relative sensitivity for this peak, to be used for quantification in ...

Relative sensitivity for this peak, to be used for quantification in an NXprocess.

As an example, in X-ray spectroscopy could depend on the energy scale (see position), the ionization cross section, and the element probed.

relative_area: (optional) NX_NUMBER {units=NX_ANY}

Relative area of this peak compared to other peaks. ...

Relative area of this peak compared to other peaks.

The relative area can simply be derived by dividing the total_area by the total area of all peaks or by a more complicated method (e.g., by additionally dividing by the relative sensitivity factors). Details shall be given in global_fit_function.

backgroundBACKGROUND: (optional) NXfit_background

One fitted background (functional form, position, and intensities) of the peak ...

One fitted background (functional form, position, and intensities) of the peak fit. If there is no characteristic name for each peak component, it is envisioned that backgrounds are labeled as background_0, background_1, and so on.

global_fit_function: (optional) NXfit_function

formula: (optional) NX_CHAR

Oftentimes, if the peaks and fit backgrounds are defined independently (i.e, ...

Oftentimes, if the peaks and fit backgrounds are defined independently (i.e, with their own parameter sets), the resulting global fit is a function of the form \(model = peak_1(p_1) + peak2(p_2) + backgr(p_3).\), where each \(p_x\) describes the set of parameters for one peak/background.

error_function: (optional) NXfit_function

Function used to optimize the parameters during peak fitting.

description: (optional) NX_CHAR

Description of the method used to optimize the parameters during peak fittin ...

Description of the method used to optimize the parameters during peak fitting. Examples: - least squares - non-linear least squares - Levenberg-Marquardt algorithm (damped least-squares) - linear regression - Bayesian linear regression

formula: (optional) NX_CHAR

For the optimization, the formula is any optimization process on the `global ...

For the optimization, the formula is any optimization process on the global_fit_function given above. As an example, for a linear least squared algorithm on independent components, the formula of the error_function would be \(LLS(peak_1(p_1) + peak2(p_2) + backgr(p_3))\), where each \(p_x\) describes the set of parameters for one peak/background.

It is however also possible to supply more involved formulas (e.g., in the case of constrained fits).

Hypertext Anchors

List of hypertext anchors for all groups, fields, attributes, and links defined in this class.

NXDL Source:

https://github.com/FAIRmat-NFDI/nexus_definitions/tree/fairmat/contributed_definitions/NXfit.nxdl.xml