The FitSpec algorithm uses noise analysis for setting some of the fitting parameters (‘par.cutoff’ and ‘par.npp’). If noise analysis is performed, either to determine these parameters or because the user sets ‘par.noise_eval’ to ‘y’, then the result is returned in ‘fit.noise’, and also a calculation of the reduced-chi-squared of the spectrum fit is returned. Noise analysis consists of first generating synthetic noise, and determining a probability distribution of the heights of noise peaks, and secondarily, from fitting that distribution to experimental peaks. The fields in ‘fit.noise’ are summarized below.
noise.x: This is the x-axis for the calculated probability distribution of peak heights, such that the values in ‘noise.x’ are peak amplitudes. The values in ‘noise.x’ have been scaled to be a best fit to the experimental peaks. Note that this distribution only includes concave down noise peaks, although the concave up peaks would have an x-axis equal to –noise.x.
noise.fx: This is the probability density corresponding to each value in ‘noise.x’. The distribution is normalized such that the values in ‘noise.fx’ add up to one.
noise.x_exp: This is the x-axis for the experimental noise peaks, which have been grouped using a histogram (‘histc’ function). As with ‘noise.x’, this then corresponds to experimental noise peak amplitudes.
noise.count_exp: This gives the number of experimental peaks at amplitude given in ‘noise.x_exp’. Note that the total count has been scaled so that the values in ‘noise.fx’ and ‘noise.count_exp’ correspond. The un-scaled count can be obtained with the following:
noise.count_exp*noise.np_exp/sum(noise.count_exp)
noise.np: This is the number of synthetic noise peaks measured. This number includes both positive and negative (concave up and concave down) noise peaks. It is a good estimate for the number of noise peaks expected in the experimental spectrum, not considering that real peaks will sit on top of the noise peaks.
noise.np_exp :
This is the number of experimental peaks considered in the noise analysis. This will vary considerably, depending on whether regions of noise were specified, and on the ‘par.sign’ setting.
noise.rms: This is the root mean square of the amplitude of spectrum noise. It is determined from the fitting of synthetic noise to experimental noise. Therefore, it should not be heavily biased by artifacts or real peaks, even if no noise region has been specified.
noise.noise: This is the root mean square of noise peaks, and so is higher than the value of noise.rms, since it is selective for local maxima. It is also obtained by fitting synthetic noise to experimental noise.
noise.n_fit_noise_pks:
This is an estimate of the number of noise peaks that will be above ‘par.cutoff’ in the final peak picking step. This is based on the fitting of the synthetic noise distribution to the experimental noise and the number of synthetic noise peaks measured (‘noise.np’). If FitSpec is calculating the value of ‘par.cutoff’, then it attempts to set this parameter to a particular amount (see ‘par.noise_frac’ and ‘par.n_noise_pks’ in 2.2.6).
The synthetic noise distribution and its fit to the experimental noise can easily by compared using the following:
bar(fit.noise.x_exp,fit.noise.count_exp);
hold all
plot(fit.noise.x,fit.noise.fx)
One usually observes differences between the synthetic and experimental noise. Partly, this is due to the resolution of the histogram of the experimental noise, but also occurs because the experimental noise also usually includes various spectrum artifacts, that are not produced in the synthetic noise distribution. Due to the fitting of synthetic to experimental noise, however, these artifacts have very little effect on noise characterization.
Aside from the ‘noise’ structure, the following fields are also reported in the output structure, ‘fit’.
fit.chi_red: The reduced-chi-squared is returned if noise analysis is performed. The value returned for ‘fit.chi_red’ is calculated according to:
fit.chi_red=1/(N-n_fit)*sum((I_exp(:)-I_calc(:)).^2/rms^2);
Here, rms is the value returned in ‘fit.noise.rms’ (see 2.4.2). I_exp and I_calc are the intensities at each point in the spectrum of the experimental and calculated spectra, respectively. N is the number of points in the spectrum, and n_fit is the total number of fit variables being used to the fit the spectrum.
fit.resnorm: ‘fit.resnorm’ returns the value of the squared 2-norm of the fit residual, as given by
fit.resnorm=sqrt(sum((I_exp(:)-I_calc(:)).^2));
where the parameters are the same as those for ‘fit.chi_red’.