Chemometric and forensic-comparison analysis of chemical samples measured by GC-MS and LC-MS. This notebook imports mass-spectrometry data and apply a range of chemometric methods (PCA, HCA) together with a likelihood-ratio (LR) framework to investigate linkages between samples.
The analysis focuses on samples containing DIMP, DC and IPA. Feature tables are
produced by external tools (mzmine for GC-MS, Compound Discoverer for LC-MS),
imported here, and evaluated to quantify the strength of evidence for a common
source using likelihood ratios via the lir
library.
.
├── data/ # Raw input data (mzmine / Compound Discoverer exports, sample names)
├── df/ # Intermediate/processed data frames
├── img/ # Generated figures
└── *.ipynb # Analysis notebooks
This project uses uv for environment and dependency management.
# Create the virtual environment and install dependencies from the lockfile
uv syncThen open any notebook in VS Code (or run jupyter lab) and select the
.venv kernel.
Input files are expected in the data/ folder (relative to the notebook). For
example, the GC-MS notebook reads data/GCMS_widetable_corr_public.csv. Place the
required export files in data/ before running the notebooks.
- Figures produced by the notebooks are written to
img/. - Result data frames are written to
df/.
M. de Bruin-Hoegée, Python code for Icarus, (2026). https://doi.org/10.5281/zenodo.21345942.