Abstract
Our Python package, nmrfit, reads the output from an nuclear magnetic resonance (NMR) experiment and, through a number of intuitive API calls, produces a least-squares fit of Voigt-function approximations via particle swarm optimization. Fitted peaks can then be used to perform quantitative NMR analysis, including isotope ratio approximation. There are two alternatives in this space (nmrglue and lmfit), but both are insufficient in that: Voigt functions are not area parameterized, limiting signal contribution quantification accuracy (necessary to calculate isotope ratios). Optimization methods are not robust enough for isotope ratio applications. For example, carbon-12 peaks dominate carbon-13 peaks in terms of relative intensity, causing many optimization methods to fit the former extremely well, but largely ignore the latter. Our software includes a dynamic-weighting scheme and optimization by particle swarm to robustly and faithfully fit peaks regardless of relative intensity differences. Initial parameter selection tools are either lacking or insufficient. Our software supplies utilities for bounds selection, automatic or manual peak selection, and a number of options for initial phase correction. In-phase data is required. Our approach requires an initial, approximate phase correction for seed parameter determination, but the zeroth- and first- order phase are fit parameters, which is novel in this space. Supplied APIs are not particularly intuitive. Our offering requires only ~10 lines of code to go from data input to publication-quality plots, all through intuitive function and method calls.
Exploratory License
Eligible for exploratory license
Market Sector
Chemistry and Catalysts