https://github.com/scverse/pertpy
Single-cell perturbation analysis
https://github.com/scverse/pertpy
perturbation scverse single-cell
Last synced: about 2 months ago
JSON representation
Single-cell perturbation analysis
- Host: GitHub
- URL: https://github.com/scverse/pertpy
- Owner: scverse
- License: mit
- Created: 2021-06-23T14:15:02.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2026-03-19T22:08:39.000Z (2 months ago)
- Last Synced: 2026-03-20T13:17:47.693Z (2 months ago)
- Topics: perturbation, scverse, single-cell
- Language: Python
- Homepage: https://pertpy.readthedocs.io/en/stable
- Size: 97.2 MB
- Stars: 295
- Watchers: 5
- Forks: 54
- Open Issues: 35
-
Metadata Files:
- Readme: README.md
- Contributing: docs/contributing.md
- License: LICENSE
Awesome Lists containing this project
- top-life-sciences - **scverse/pertpy** - cell`<br><img src='https://github.com/HubTou/topgh/blob/main/icons/gstars.png'> 87 <img src='https://github.com/HubTou/topgh/blob/main/icons/forks.png'> 19 <img src='https://github.com/HubTou/topgh/blob/main/icons/code.png'> Python <img src='https://github.com/HubTou/topgh/blob/main/icons/license.png'> MIT License <img src='https://github.com/HubTou/topgh/blob/main/icons/last.png'> 2024-06-08 08:07:34 | (Ranked by starred repositories)
README
[](https://github.com/scverse/pertpy/actions/workflows/build.yml)
[](https://codecov.io/gh/scverse/pertpy)
[](https://opensource.org/licenses/Apache2.0)
[](https://pypi.org/project/pertpy/)
[](https://pypi.org/project/pertpy)
[](https://pertpy.readthedocs.io/)
[](https://github.com/scverse/pertpy/actions/workflows/test.yml)
[](https://github.com/pre-commit/pre-commit)
# pertpy - Perturbation Analysis in Python
Pertpy is a scverse ecosystem framework for analyzing large-scale single-cell perturbation experiments.
It provides tools for harmonizing perturbation datasets, automating metadata annotation, calculating perturbation distances, and efficiently analyzing how cells respond to various stimuli like genetic modifications, drug treatments, and environmental changes.
Please read our associated manuscript ["Pertpy: an end-to-end framework for perturbation analysis"](https://www.nature.com/articles/s41592-025-02909-7).

## Documentation
Please read the [documentation](https://pertpy.readthedocs.io/en/latest) for installation instructions, tutorials, use cases, and more.
## Installation
We recommend installing and running pertpy on a recent version of Linux (e.g. Ubuntu 24.04 LTS).
No particular hardware beyond a standard laptop is required.
You can install _pertpy_ in less than a minute via [pip] from [PyPI]:
```console
pip install pertpy
```
or [conda-forge]:
```console
conda install -c conda-forge pertpy
```
### Differential gene expression
If you want to use the differential gene expression interface, please install pertpy by running:
```console
pip install 'pertpy[de]'
```
### tascCODA
if you want to use tascCODA, please install pertpy as follows:
```console
pip install 'pertpy[tcoda]'
```
### milo
milo requires either the "de" extra for the "pydeseq2" solver:
```console
pip install 'pertpy[de]'
```
or, edger, statmod, and rpy2 for the "edger" solver:
```R
BiocManager::install("edgeR")
BiocManager::install("statmod")
```
```console
pip install rpy2
```
## Citation
```bibtex
@article{Heumos2025,
author = {Heumos, Lukas and Ji, Yuge and May, Lilly and Green, Tessa D. and Peidli, Stefan and Zhang, Xinyue and Wu, Xichen and Ostner, Johannes and Schumacher, Antonia and Hrovatin, Karin and Müller, Michaela and Chong, Faye and Sturm, Gregor and Tejada, Alejandro and Dann, Emma and Dong, Mingze and Pinto, Gonçalo and Bahrami, Mojtaba and Gold, Ilan and Rybakov, Sergei and Namsaraeva, Altana and Moinfar, Amir Ali and Zheng, Zihe and Roellin, Eljas and Mekki, Isra and Sander, Chris and Lotfollahi, Mohammad and Schiller, Herbert B. and Theis, Fabian J.},
title = {Pertpy: an end-to-end framework for perturbation analysis},
journal = {Nature Methods},
year = {2025},
publisher = {Springer Nature},
doi = {10.1038/s41592-025-02909-7},
url = {https://doi.org/10.1038/s41592-025-02909-7},
issn = {1548-7105}
}
```
[pip]: https://pip.pypa.io/
[pypi]: https://pypi.org/
[api]: https://pertpy.readthedocs.io/en/latest/api.html
[conda-forge]: https://anaconda.org/conda-forge/pertpy
[//]: # "numfocus-fiscal-sponsor-attribution"
pertpy is part of the scverse® project ([website](https://scverse.org), [governance](https://scverse.org/about/roles)) and is fiscally sponsored by [NumFOCUS](https://numfocus.org/).
If you like scverse® and want to support our mission, please consider making a tax-deductible [donation](https://numfocus.org/donate-to-scverse) to help the project pay for developer time, professional services, travel, workshops, and a variety of other needs.