BiPCA is a Python package for processing high-dimensional omics count data, such as scRNAseq, spatial transcriptomics, scATAC-seq, and many others. BiPCA first scales the rows and columns of the data to make the noise approximately homoscedastic (biwhitening step), which reveals the underlying rank of the data (based on MP distribution). Then, BiPCA performs optimal shrinkage of singular values to recover the biological signal (denoising step).
Installation
Pip installation
You can install BiPCA from PyPI:
pip install biPCA
To install with optional experiment dependencies:
pip install biPCA[experiments]
Alternatively, to install from source:
pip install 'git+https://github.com/KlugerLab/bipca.git#subdirectory=python'
Or from source with experiment dependencies:
pip install 'biPCA[experiments] @ git+https://github.com/KlugerLab/bipca.git#subdirectory=python'
Docker installation
Alternatively, we recommend installing BiPCA with the accompanied bipca-experiment Docker environment. This image reproduces the environment we used to make the BiPCA manuscript. The pre-built docker image can be downloaded using:
docker pull jyc34/bipca-experiment:lastest
and to run the Docker container:
docker run -it --rm -e USER=john -e USERID=$(id -u) --name bipca -p 8080:8080 -p 8029:8787 \
-v /data/:/data/ docker.io/jyc34/bipca-experiment:lastest /bin/bash
Here, change /data/:/data to <your_local_data_directory>:/data. A JupyterLab will be launched on host port 8080 and an RStudio will be on port 8029. If you would like to link a local bipca installation (for package development, for instance), you can use -v <your_local_bipca_directory>:/bipca.
See detailed descriptions regarding the Docker image usage and information on the corresponding Dockerfile.
Getting Started
Running BiPCA with a built-in dataset: tutorial-0-quick_start.ipynb
Running BiPCA with an unfiltered dataset from scanpy: tutorial-1-pbmc_scrna_scanpy.ipynb
Reproducing figures
Codes for generating the figures used in the manuscript are documented as individual functions in figure.py. For example, run the following to reproduce the marker gene figure:
from bipca.experiments.figures import Figure_marker_genes
fig_obj = Figure_marker_genes(base_plot_directory="./result/",
output_dir="./data/",
formatstr="png")
fig_obj.plot_figure(save=True)
Figure1_Suppfig1.ipynb regenerates Fig1 and Supplemental Fig1 used in the manuscript.
Reference
If you use BiPCA for your research, please cite accordingly.
Metadata
Release files for biPCA 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| bipca-1.1.0.tar.gz | 2.1 MB | With provenance | Details for bipca-1.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| bipca-1.1.0-py3-none-any.whl | Python 3 | none | any | Details for bipca-1.1.0-py3-none-any.whl |
Total release size: 2.8 MB
Release files / bipca-1.1.0.tar.gz
| Download URL | bipca-1.1.0.tar.gz |
|---|---|
| Size | 2.1 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f77f95b9dbd8ecfb9461098a149cf70d95dd691f22037358fed6e7d6874884bb
|
|
BLAKE2b-256 checksum How to use checksums |
6bf6dbdf131f1149f944217c2f74882553078931cbfb76b5d4c1b011086ab9df
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 3, 2026.
Transparency logRelease files / bipca-1.1.0-py3-none-any.whl
| Download URL | bipca-1.1.0-py3-none-any.whl |
|---|---|
| Size | 657.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
67cdc880e080ffb34f11228e938b1dc9adc7c9afef7af895cd6eed125c1e445a
|
|
BLAKE2b-256 checksum How to use checksums |
8a72e81e8c72696ae04dbed55d6e66efe3d1a57ce555f9ac219374b25cafd344
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 3, 2026.
Transparency logSecurity for biPCA 1.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for bipca-1.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 3, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.