3CIsoInvert

Published: 6 September 2026| Version 1 | DOI: 10.17632/yykdgptr5j.1
Contributors:
Dhanya Gelli,

Description

3CIsoInvert is a Python package that implements a probabilistic Bayesian framework for testing whether measured isotope compositions of lamproite are consistent with mixing between mantle (plume) and metasome endmembers (MARID; PIC; mica-peridotites, etc.). The code evaluates both two-component (plume + one metasome) and three-component (plume + hybrid mixture of two metasomes) mixing models against multi-dimensional Sr–Nd–Hf–Pb isotope data. The three-component mixing is critical to this approach because it circumvents the limited availability of isotope data of metasome end-members by generating a spectrum through hybrid mixtures. The inversion is built on concentration-weighted mixing equations that predict isotope ratios as functions of mixing fractions. Model misfit is quantified via χ², computed across all usable isotope ratios. The code propagates analytical uncertainties through Monte Carlo sampling instead of treating endmember ratios and concentrations as fixed. Isotope ratios are drawn from Gaussian distributions, while element concentrations are drawn from log-normal distributions to ensure strictly positive values. At each grid point, thousands of sampled candidates are evaluated, and the resulting likelihoods are averaged to produce a likelihood surface that reflects both model fit quality and the impact of end-member uncertainty. We used a two-tier screening process to keep the analysis computationally efficient. Tier 1 evaluates each candidate per isotope space individually using relatively few Monte Carlo draws; two-component candidates must pass a genuine goodness-of-fit test (degrees of freedom = 1), while three-component candidates automatically survive (degrees of freedom = 0) and defer discrimination to Tier 2. Surviving candidates are then re-evaluated jointly across all usable ratios with higher Monte Carlo sample counts, yielding final χ², p-values, and log-evidence rankings. Candidates are compared only within groups sharing the same usable-ratio set, since different ratio combinations carry different likelihood normalisations. For multi-grain analyses of the same mineral phase, inverse-variance pooling is applied with MSWD-based uncertainty inflation to account for disequilibrium scatter. Results are written to Excel workbooks containing ranked candidate solutions, per-space deterministic fits, multiple-comparison diagnostics, and cluster statistics. The complete package, including source code, configuration parameters, and convergence diagnostics, is available for peer review and independent replication.

Files

Categories

Isotope Geochemistry

Licence