Skip to main content

compare

Function compare 

Source
pub fn compare(
    model: &dyn ElectronicStopping,
    correction: &dyn CompoundCorrection,
    dataset: &StoppingDataset,
) -> Comparison
Expand description

Compare model against every point of dataset.

An element target is evaluated with ElectronicStopping::stopping; a compound with bragg_cross_section_per_atom and correction (which is not applied to element targets). Residuals follow the sign convention of PointResidual: positive when the model is above the measurement. A point where the model returns an error (such as StoppingError::NotApplicable) is listed in Comparison::skipped with that error, never dropped silently.