Skip to main content

XH-/PI interaction detection

Project description

Xpid

Xpid is a Gemmi-based tool designed to detect XH-π interactions in PDB/mmCIF files.

Installation

Requires Python 3.9+.

git clone https://github.com/SeanWang5868/xpid
cd xpid
pip install .

Configuration

The detection of XH-π interactions depends on the position of H atoms. In order to add H to the structure before detecting, the path to the monomer library (e.g. CCP4 monomer library) needs to be specified.

xpid --set-mon-lib /Users/abc123/monomers

Quick Start

Scans a directory or PDB/mmCIF file and save results into a JSON file.

xpid ./data

Output: ./data/xpid_output/xpid_results.json

Geometric Criteria

Definitions: $C_\pi$ (Ring Centroid), $\vec{n}$ (Ring Normal), $X$ (Donor Heavy Atom), $Xp$ (The projection of X onto the π plane), $H$ (Hydrogen).

Hudson System

$d_{X \text{--} C_\pi}$: $\le 4.5$ Å, $\angle X\text{--}H \text{--} \vec{n}$): $\le 40^\circ$. $d_{Xp \text{--} C_\pi}$: $\le 1.6$ Å $\text{for His, Trp-A}$, $\le 2.0$ Å $\text{for Phe, Trp-B, Tyr}$.

Plevin System

$d_{X \text{--} C_\pi}$: $< 4.3$ Å, $\angle X\text{--}H \text{--} C_\pi$: $> 120^\circ$, $\angle X \text{--} C_\pi \text{--} \vec{n}$): $< 25^\circ$.

Command Options

Argument Description
inputs Input file (.cif, .pdb) or directory path.
--out-dir Specify custom output directory.
--separate Save results as separate files per PDB (Default: Merge).
--file-type Output format: json (default) or csv.
-v, --verbose Output detailed metrics (angles, coords, B-factors).
--log Enable log file saving.
--jobs N Number of CPU cores to use (Default: 1).
--h-mode N Hydrogen handling mode (0=NoChange, 4=ReAddButWater).
--model ID Model index to analyze (Default: 0; use all for NMR).
--pi-res Limit acceptor residues (e.g., TRP,TYR).
--donor-res Limit donor residues (e.g., HIS,ARG).
--donor-atom Limit donor element types (e.g., N,O).

Output Data

Simple Mode (Default)

  • PDB ID, Resolution
  • Chain, Name, ID for X-donor and $\pi$ Residues.
  • Distance ($d_{X \text{--} C_\pi}$)

Detailed Mode (-v)

  • Includes all Simple fields plus:
  • Secondary structure: Type (H/G/I/E/C) and Region IDs.
  • Coordinates: Flattened x, y, z for $\pi$-center and X-atom.
  • Geometric parameters: $\angle X\text{--}H \text{--} \vec{n}$, $\angle X\text{--}H \text{--} C_\pi$, $\angle X \text{--} C_\pi \text{--} \vec{n}$, $d_{Xp \text{--} C_\pi}$
  • B-factors: Average B-factor for ring atoms and X-atom.

Dependencies

  • gemmi
  • numpy

Contact

Sean Wang (sean.wang@york.ac.uk)

York Structural Biology Laboratory (YSBL), University of York

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

xpid-0.0.1.tar.gz (15.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

xpid-0.0.1-py3-none-any.whl (15.7 kB view details)

Uploaded Python 3

File details

Details for the file xpid-0.0.1.tar.gz.

File metadata

  • Download URL: xpid-0.0.1.tar.gz
  • Upload date:
  • Size: 15.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for xpid-0.0.1.tar.gz
Algorithm Hash digest
SHA256 6ea5121b76a26ecabd8558f8371a5fbaa249805851e323d78c962e57465750bf
MD5 5528017c6001d3b10af10cf7b52e4040
BLAKE2b-256 c916e07e0792f74e7a5cff20146f37648bd99c389bd8de70f58b11e083940c77

See more details on using hashes here.

File details

Details for the file xpid-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: xpid-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 15.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for xpid-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 576c8ff62dec3632432294d74fae097027a7c7ebecdc61c0f39b5408343f688a
MD5 6baa794dbaa712938cbfaef263fafcac
BLAKE2b-256 b4113bbc56cc0f55535b6edabb2120095195c31ae8059f8b0b107b0497aefe6b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page