Welcome to scPPIN-py

Pure Python implementation of scPPIN with class-based API

scPPIN-py detects functional modules in protein-protein interaction networks by integrating single-cell RNA sequencing data. This is a reimplementation of the original R package with a clean, object-oriented API.

Note

Original Method: The method is described in Klimm et al. (2020) (BMC Genomics 21, Article number: 756).

Key Features

  • Class-Based API: Object-oriented design with setup method chaining

  • Pure Python: No external C++ binaries (uses pcst_fast)

  • Edge Weights: Supports confidence scores or computed correlations

  • Author’s Formula: Implements recommended edge cost formula from GitHub Issue #10

  • Scanpy Integration: Works seamlessly with AnnData objects

  • Fast: Vectorized NumPy operations, ~5-10x faster than R

  • Easy Installation: Single pip install command

  • Automatic Filtering: Network automatically filtered to genes with p-values

Quick Start

Install scPPIN-py from GitHub:

pip install git+https://github.com/shahrozeabbas/scppin-py.git

Quick Example

from scppin import scPPIN

# Create model instance
model = scPPIN()

# Load network from edge list
model.load_network('edges.csv')

# Set node weights (p-values)
pvalues = {'TP53': 0.0001, 'MDM2': 0.001, 'CDKN1A': 0.005}
model.set_node_weights(pvalues)

# Detect functional module
module = model.detect_module(fdr=0.01)

# Visualize
model.plot_module(fdr=0.01)

See the Quick Start guide for more details.

Documentation Contents

API Reference

Additional Resources

Citation

If you use this package, please cite the original paper:

@article{klimm2020functional,
  title={Functional module detection through integration of single-cell RNA
         sequencing data with protein--protein interaction networks},
  author={Klimm, Florian and Toledo, Enrique M and Monfeuga, Thomas and
          Zhang, Fang and Deane, Charlotte M and Reinert, Gesine},
  journal={BMC genomics},
  volume={21},
  number={1},
  pages={1--10},
  year={2020},
  publisher={BioMed Central}
}

License

GPL-3.0 (same as original R package)