Metadata-Version: 2.4
Name: phenoms
Version: 0.2.0
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Rust
Requires-Dist: mdtraj>=1.9
Requires-Dist: polars>=1.0
Requires-Dist: pandas>=1.0
Requires-Dist: numpy>=1.20
Requires-Dist: matplotlib>=3.5
Requires-Dist: seaborn>=0.11
Requires-Dist: tqdm>=4.60
Requires-Dist: joblib>=1.0
Requires-Dist: scikit-learn>=1.0
Requires-Dist: networkx>=3.0
Requires-Dist: click>=8.0
Requires-Dist: mdanalysis>=2.4 ; extra == 'benchmark'
Requires-Dist: pytest>=7.0 ; extra == 'dev'
Requires-Dist: pytest-cov>=4.0 ; extra == 'dev'
Requires-Dist: sphinx>=7.0,<9 ; extra == 'docs'
Requires-Dist: shibuya>=2024.7.0 ; extra == 'docs'
Requires-Dist: myst-parser>=3.0 ; extra == 'docs'
Requires-Dist: biopython>=1.79 ; extra == 'structure'
Provides-Extra: benchmark
Provides-Extra: dev
Provides-Extra: docs
Provides-Extra: structure
License-File: LICENSE
Summary: Backbone H-bond network analysis for MD simulations (HDX-MS style)
Keywords: molecular-dynamics,hydrogen-bonds,HDX-MS,backbone
Author-email: Brandon Novy <bcnovy96@gmail.com>
License: MIT
Requires-Python: >=3.8
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM

# PHENOMS

Python-based Hydrogen-Deuterium Exchange of Molecular Dynamics Simulations

![PHENOMS workflow](./assets/phenoms.png)

**Documentation:** [https://brandon-cole.github.io/PHENOMS/](https://brandon-cole.github.io/PHENOMS/)

PHENOMS analyzes backbone H-bond networks from MD trajectories for HDX-MS–style interpretation: Rust-accelerated Baker–Hubbard detection, replicate/`ComparisonSet` workflows, occupancy heatmaps, differential protection, and connectivity exports. Backbone N–O is the default; all-bond mode and native traj+topology inputs are optional.

## Install

Install [Rust](https://rustup.rs/) first, then:

```bash
conda env create -f environment.yml
conda activate phenoms
pip install -e .
```

`pip install -e .` builds the Rust kernel (`phenoms.phenoms_hbond_rs`) into the
same package via [maturin](https://www.maturin.rs/). Without a Rust toolchain
at install time, PHENOMS falls back to MDTraj for detection.

## Quick start

```python
from phenoms import SimulationSet, ComparisonSet, default_output_root

sim = SimulationSet(
    pdb_files=["rep1.pdb", "rep2.pdb"],
    resid_range=(50, 70),
    sub_frames=100,
    output_dir=default_output_root() / "my_run",
)
sim.run()

a = SimulationSet(["a1.pdb", "a2.pdb"], sub_frames=100)
b = SimulationSet(["b1.pdb", "b2.pdb"], sub_frames=100)
cmp = ComparisonSet(a, b, label_a="apo", label_b="holo")
a.run(); b.run()
cmp.compare()
cmp.export_comparison_artifacts(default_output_root() / "comparison")
```

CLI (optional): `phenoms prep`, `phenoms run`, `phenoms compare` — see the [docs](https://brandon-cole.github.io/PHENOMS/).

Outputs default to `./phenom_outputs/` (or `$PHENOMS_OUTPUT_DIR`).

## Benchmarks

Kernel timing (Docker, 4 CPUs, 3×250 frames, 2,722 atoms): Rust **0.047 s** vs MDTraj **0.803 s** (~17×) vs MDAnalysis **1.126 s** (~24×). Reproduce via [docker/README.md](./docker/README.md).

## License

[MIT](./LICENSE)

