SetMassCalib2Ex: Configures the mass calibration that will be used for the...

View source: R/RcppExports.R

SetMassCalib2ExR Documentation

Configures the mass calibration that will be used for the next acquisition.

Description

SetMassCalib2Ex configures the mass calibration that will be used for the next acquisition(s). If nbrParams is 0, the calibration parameters are determined by the TofDaq recorder based on the mass, tof and weight arrays. If calibration parameters and calibration point information is supplied the calibration parameters define the calibration (no "sanity" check is performed whether the point information yields the same mass calibration parameters). Labels to identify compound names/formulas used for calibration have a maximum length of 255 characters.

Usage

SetMassCalib2Ex(mode, nbrParams, p, mass, tof, weight, label)

Arguments

mode

Mass calibration function to use.

nbrParams

Number of mass calibration parameters.

p

Vector with mass calibration parameters.

mass

Vector with mass of the calibration points.

tof

Vector with TOF sample index of the calibration points.

weight

Vector with weight of the calibration points.

label

Vector with labels of the calibration points.

Details

mode Mass calibration function
0 i = p_1 \sqrt(m) + p_2
1 i = p_1/\sqrt(m) + p_2
2 i = p_1 m^{p_3} + p_2
3 i = p_1 \sqrt(m) + p_2 + p_3 (m - p_4)^2
4 i = p_1 \sqrt(m) + p_2 + p_3 m^2 + p_4 m + p_5
5 m = p_1 i^2 + p_2 i + p_3

Note: Modes 3 and 4 are flawed. Don't use them. In mode 3 the fit does not converge well, because of a bug (parameters not correctly initialized). Mode 4 is two sequential fits, first mode 0, then a quadratic fit to the residuals, which is an inferior implementation of mode 3. Mode 1 is for FTMS data.


pasturm/TofDaqR documentation built on March 29, 2024, 12:10 a.m.