Skip to main content

ProbeDataTools

ProbeDataTools is a Python package for processing mineral and liquid compositions acquired using an electron microprobe.

It provides an alternative to specialised spreadsheet-based workflows, where calculations are often hidden in cell formulae and need to be modified when different oxides are analysed. ProbeDataTools instead provides transparent, reusable calculations that are largely independent of mineral type and analytical setup.

The package includes data for 46 commonly analysed oxides in oxides.csv. Additional analytical species can be added without modifying the calculation code.

Citation

ProbeDataTools is open-source software released under the MIT License. You are welcome to use, modify, and adapt the code.

If you use ProbeDataTools in research or published work, please cite the software using the citation information provided in CITATION.cff.

When using calculations that implement published methods, please also cite the original methodological source.

Functionality

  • Convert analytical wt% to atoms per formula unit (APFU).
  • Calculate molar and cation proportions and fractions.
  • Estimate Fe2+/Fe3+ using published stoichiometric methods.
  • Calculate endmember components for olivine, feldspar, clinopyroxene and spinel.
  • Identify potentially anomalous analyses from apfu totals.

Basic Usage

ProbeDataTools uses pandas DataFrames for analytical data.

import pandas as pd

from probedatatools import ProbeData
from probedatatools.cations import calc_apfu

data = pd.read_excel("olivine_data.xlsx")
species = ["SiO2", "FeO", "MgO", "MnO", "CaO"]

probe = ProbeData(data, species)
apfu = calc_apfu(probe, afu=4)

calc_apfu() is not specific to olivine: the same function can be used for any mineral given the appropriate number of oxygens per formula unit.

For example, an amphibole analysis can be calculated on a 23-oxygen basis:

species = [
    "SiO2", "TiO2", "Al2O3", "FeO", "MgO",
    "CaO", "Na2O", "K2O", "F", "Cl",
]

probe = ProbeData(data, species)
apfu = calc_apfu(probe, afu=23)

Analysed non-oxygen anions such as F and Cl are identified from the species definitions and reported automatically in the resulting APFU dataframe. They do not contribute to the oxygen renormalisation factor.

Metadata

Release files for probedatatools 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for probedatatools 0.1.0
File Size Uploaded
probedatatools-0.1.0.tar.gz 24.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for probedatatools 0.1.0
File Interpreter ABI Platform
probedatatools-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 40.9 kB

Release files / probedatatools-0.1.0.tar.gz

Download URL probedatatools-0.1.0.tar.gz
Size 24.4 kB
Tags Source
SHA-256 checksum
How to use checksums
0fd97ccccf99991a4637de56aa05285ae6469326d89b17b104b1771ea435e03b
BLAKE2b-256 checksum
How to use checksums
027bfb4df00ff0952dc8147f1c56e349ae2171c2ef3ebc1bc05ceca9121a1aac
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 26, 2026.

Transparency log

Release files / probedatatools-0.1.0-py3-none-any.whl

Download URL probedatatools-0.1.0-py3-none-any.whl
Size 16.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f5a689348584eb377ded8425d1fcf1016f859463de7d7d6e7abe9d1ec6eaae85
BLAKE2b-256 checksum
How to use checksums
ec79e07e6105dff28f0c77bb55f09b5959ab7a9ca55a5cea1e46c8f7ed1788c2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 26, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page