| make_velo_count | R Documentation |
Parses and processes spliced and unspliced gene expression matrices from one or more Velocyto output directories. The function applies barcode filtering using an external whitelist or filtered barcodes file, and optionally merges the results across samples into unified matrices.
make_velo_count(
velocyto_dirs,
sample_ids,
whitelist_barcodes = NULL,
use_internal_whitelist = TRUE,
merge_counts = FALSE,
verbose = FALSE
)
velocyto_dirs |
A character vector or list of strings. Each element should be a path to a Velocyto output directory.
Each directory must contain subdirectories (typically |
sample_ids |
A character vector or list of unique sample identifiers corresponding to each entry in |
whitelist_barcodes |
A list of character vectors. Each element should provide a whitelist of barcodes to retain for the
corresponding sample. If |
use_internal_whitelist |
Logical (default |
merge_counts |
Logical (default |
verbose |
Logical. If |
The function assumes that each Velocyto directory follows the 10X-like structure typically produced by tools like Loom or Velocyto CLI. Barcode filtering ensures that only high-quality or selected barcodes are retained for downstream RNA velocity analysis.
When merging matrices, barcodes are prefixed with their corresponding sample ID to avoid collisions and preserve traceability.
A list containing processed gene expression matrices:
If merge_counts = FALSE, returns a named list of sample-specific matrices. Each entry contains:
splicedSparse matrix of spliced transcript counts.
unsplicedSparse matrix of unspliced transcript counts.
If merge_counts = TRUE, returns a list with two elements:
splicedMerged sparse matrix of spliced counts across all samples.
unsplicedMerged sparse matrix of unspliced counts across all samples.
Requires the Matrix package for sparse matrix operations and data.table for efficient file parsing.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.