This repository contains scripts and notebooks to reproduce the experiments in Visualizing single-cell data with the neighbor embedding spectrum (bioarxiv)
It depends on the ne-spectrum
package, which computes neighbor embedding spectra.
Neighbor embedding spectrum on developmental human brain organoid data from Kanton et al. 2019.
Higher attraction improves the global structure as measured by Spearman distance correlation. Higher repulsion improves local structure as measured by kNN recall.
Create and activate the conda environment
conda env create -f environment.yml
conda activate ne_spectrum_scRNAseq
Install the utilities for this repository
python setup.py install
To reproduce the data for the figures in the main paper, run
python scripts/compute_embds.py --spectrum_via tsne
python scripts/compute_metrics.py --spectrum_via tsne
To reproduce the data for the figures in the supplementary, run
python scripts/compute_embds.py --spectrum_via cne
python scripts/compute_metrics.py --spectrum_via cne
Then run the notebooks in notebooks/
to generate the figures and the videos.