This repository contains a Python implementation of singleCellHaystack (version >= 1.0.0).
This package is currently in beta. The most important functionality in the R package works, but some features are not yet available. Here is a (probably imcomplete) list of missing features. Some will be added in the future.
weights.advanced.Q
(formerly known asuse.advanced.sampling
).seeding
method for calculating grid points.- Hierarchical clustering method for
cluster_genes
.
You can install singleCellHaystack from PyPI:
pip install singleCellHaystack
You can install singleCellHaystack from GitHub with:
pip install git+http://github.com/ddiez/singleCellHaystack-py
Support for conda installation will be added in the future.
import scanpy as sc
import singleCellHaystack as hs
adata = sc.read_h5ad("data.h5ad")
[... process adata object ...]
res = hs.haystack(adata, basis="pca")
res.top_features(n=10)
-
Our manuscript describing the updated, more generally applicable version of
singleCellHaystack
including this Python implementation was published in Scientific Reports. -
Our manuscript describing the original implementation of
singleCellHaystack
for R (version 0.3.4) was published in Nature Communications.
If you use singleCellHaystack
in your research please cite our work using:
Vandenbon A, Diez D (2023). “A universal tool for predicting differentially active features in single-cell and spatial genomics data.” Scientific Reports, 13(1), 11830. doi:10.1038/s41598-023-38965-2.