Add_Top_Gene_Pct | R Documentation |
Add the percentage of counts occupied by the top XX most highly expressed genes in each cell.
Add_Top_Gene_Pct(object, ...)
## S3 method for class 'liger'
Add_Top_Gene_Pct(
object,
num_top_genes = 50,
meta_col_name = NULL,
overwrite = FALSE,
verbose = TRUE,
...
)
## S3 method for class 'Seurat'
Add_Top_Gene_Pct(
object,
num_top_genes = 50,
meta_col_name = NULL,
assay = "RNA",
overwrite = FALSE,
verbose = TRUE,
...
)
object |
Seurat or LIGER object. |
... |
Arguments passed to other methods |
num_top_genes |
An integer vector specifying the size(s) of the top set of high-abundance genes. Used to compute the percentage of library size occupied by the most highly expressed genes in each cell. |
meta_col_name |
name to use for new meta data column. Default is "percent_topXX", where XX is
equal to the value provided to |
overwrite |
Logical. Whether to overwrite existing an meta.data column. Default is FALSE meaning that
function will abort if column with name provided to |
verbose |
logical, whether to print messages with status updates, default is TRUE. |
assay |
assay to use in calculation. Default is "RNA". Note This should only be changed if storing corrected and uncorrected assays in same object (e.g. outputs of both Cell Ranger and Cell Bender). |
A liger Object
A Seurat Object
This function uses scuttle package (license: GPL-3) to calculate the percent of expression
coming from top XX genes in each cell. Parameter description for num_top_genes
also from scuttle.
If using this function in analysis, in addition to citing scCustomize, please cite scuttle:
McCarthy DJ, Campbell KR, Lun ATL, Willis QF (2017). “Scater: pre-processing, quality control,
normalisation and visualisation of single-cell RNA-seq data in R.” Bioinformatics, 33, 1179-1186.
doi:10.1093/bioinformatics/btw777.
https://bioconductor.org/packages/release/bioc/html/scuttle.html
## Not run:
liger_object <- Add_Top_Gene_Pct(object = liger_object, num_top_genes = 50)
## End(Not run)
## Not run:
library(Seurat)
pbmc_small <- Add_Top_Gene_Pct(seurat_object = pbmc_small, num_top_genes = 50)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.