knowledgebase

recipes that save time

View the Project on GitHub hbc/knowledgebase

RNA Velocity analysis is a trajectory analysis based on spliced/unspliced RNA ratio.

It is quite popular https://www.nature.com/articles/s41586-018-0414-6,
however, the original pipeline is not well supported: https://github.com/velocyto-team/velocyto.R/issues

There is a new one from kallisto team: https://bustools.github.io/BUS_notebooks_R/velocity.html

1. Install R4.0 (development version) on O2

2. Install velocyto.R with R3.6.3 (Fedora 30 example)

bash:

sudo dnf update R
sudo dnf install boost boost-devel hdf5 hdf5-devel
git clone https://github.com/velocyto-team/velocyto.R

rstudio/R:

BiocManager::install("pcaMethods")
setwd("/where/you/cloned/velocyto.R")
devtools::install_local("velocyto.R")

3. Generate reference files

4. Index reference

This step takes ~1-2h and 100G or RAM:
sbatch 02_kallisto_index.sh

5. Split reads by sample with barcode_splitter

kallisto bus counting procedure works on per sample basis, so we need to split samples to separate fastq files, and merge samples across lanes.

6. Count spliced and unspliced transcripts

7. Create Seurat objects for every sample

8. Merge seurat objects

9. Velocity analysis

10. Plot velocity picture

11. Repeat marker analysis

11. References

Velocity analysis in Python: