Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/satijalab/seurat-wrappers/llms.txt

Use this file to discover all available pages before exploring further.

ReadVelocity() reads a .loom file produced by velocyto and returns a list of spliced, unspliced, and ambiguous count matrices that can be loaded into Seurat.

Syntax

ReadVelocity(
  file,
  engine = "hdf5r",
  verbose = TRUE
)

Parameters

file
character
required
Path to the .loom file generated by velocyto.
engine
character
default:"hdf5r"
HDF5 reading engine to use. Options: "hdf5r" or "rhdf5". Passed to velocyto.R::read.loom.matrices().
verbose
logical
default:"TRUE"
Print progress messages from velocyto.R.

Returns

A named list of sparse matrices:
  • spliced — spliced RNA counts
  • unspliced — unspliced (nascent) RNA counts
  • ambiguous — ambiguously spliced counts
Use as.Seurat() on this list to create a Seurat object with three separate assays.

Prerequisites

remotes::install_github("velocyto-team/velocyto.R")

Examples

library(SeuratWrappers)

# Read velocity data
ldat <- ReadVelocity(file = "sample.loom")

# Convert to Seurat with three assays: spliced, unspliced, ambiguous
object <- as.Seurat(ldat)

# Set spliced as default and preprocess
DefaultAssay(object) <- "spliced"
object <- SCTransform(object)
object <- RunPCA(object)
object <- RunUMAP(object, dims = 1:30)

# Then run velocity estimation
object <- RunVelocity(object = object, reduction = "pca", ncores = 8)

See Also

Build docs developers (and LLMs) love