View source: R/Seurat.Utils.Visualization.R
plotGeneExprHistAcrossCells | R Documentation |
Creates and optionally saves a histogram showing expression levels of specified genes within a Seurat object. Provides options for aggregate gene expression, expression threshold filtering, and quantile clipping for count data.
plotGeneExprHistAcrossCells(
genes = c("MALAT1", "MT-CO1", "MT-CO2", "MT-CYB", "TMSB4X", "KAZN"),
obj = combined.obj,
assay = "RNA",
layerX = "data",
thr_expr = 10,
suffix = NULL,
prefix = NULL,
plotname = c("Summed Gene-set Expression -", "Expression of"),
xlab = paste0("Expression -log10(Summed UMIs @", layerX, ")"),
return_cells_passing = TRUE,
clip_count_qtl_thr = 0.99,
log10_counts = TRUE,
return_quantile,
w = 9,
h = 5,
show_plot = TRUE,
...
)
genes |
Vector of gene names to include in the analysis; Default: c("MALAT1", "MT-CO1"). |
obj |
Seurat object to analyze; Default: |
assay |
Assay to use from the Seurat object; Default: "RNA". |
layerX |
Data slot to use ('data' or 'counts'); Default: "data". |
thr_expr |
Expression threshold for highlighting in the plot; Default: 10. |
suffix |
Additional text to append to the plot title; Default: NULL. |
prefix |
Additional text to prepend to the plot title; Default: NULL. |
xlab |
Label for the x-axis; Default: "log10(Summed UMI count @data)". |
return_cells_passing |
If TRUE, returns count of cells exceeding the expression threshold; Default: |
clip_count_qtl_thr |
Quantile threshold for clipping if using count data; Default: 0.95. Needed for visualization (to avoid x axis compression). |
log10_counts |
If TRUE, log10-transforms the COUNT expression values; Default: |
return_quantile |
If TRUE, returns cell count exceeding the quantile threshold; Default: |
w |
Width of the plot in inches; Default: 9. |
h |
Height of the plot in inches; Default: 5. |
show_plot |
If TRUE, displays the generated plot; Default: |
... |
Additional arguments for customization. |
Depending on the parameters, can return a ggplot object, the number of cells passing the expression threshold, or the number of cells exceeding the quantile threshold.
Depending on the parameters, can return a ggplot object, the number of cells passing the expression threshold, or the number of cells exceeding the quantile threshold.
## Not run:
plotGeneExprHistAcrossCells(obj = yourSeuratObject, genes = c("GeneA", "GeneB"))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.