View source: R/caesar_enrichscore.R
CAESAR.enrich.score | R Documentation |
This function calculates spot level enrichment scores for a list of pathways based on a cell-gene distance matrix in a Seurat object. The function uses a permutation-based approach to determine the significance of the enrichment scores.
CAESAR.enrich.score(
seu,
pathwaylist,
assay.dist = "distce",
reduction.name = "caesar",
gene.use = NULL,
n_fake = 1001,
seed = 1
)
seu |
A Seurat object containing the gene expression data. |
pathwaylist |
A list of pathways, where each pathway is represented by a vector of genes. |
assay.dist |
A character string specifying the assay that contains the distance matrix. Default is "distce". |
reduction.name |
A character string specifying the reduction method to use if the distance matrix needs to be computed. Default is "caesar". |
gene.use |
A character vector specifying which genes to use in the analysis. If |
n_fake |
An integer specifying the number of random permutations to generate for significance testing. Default is 1001. |
seed |
An integer specifying the random seed for reproducibility. Default is 1. |
A matrix of enrichment scores with cells as rows and pathways as columns.
data(toydata)
seu <- toydata$seu
pathway_list <- toydata$pathway_list
enrich.score <- CAESAR.enrich.score(seu, pathway_list)
head(enrich.score)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.