View source: R/plot_hexbin_density.R
plot_hexbin_density | R Documentation |
Plot of density of observations from single cell data in bivariate hexagon cells.
plot_hexbin_density(sce, title = NULL, xlab = NULL, ylab = NULL)
sce |
A |
title |
A string containing the title of the plot. |
xlab |
A string containing the title of the x axis. |
ylab |
A string containing the title of the y axis. |
A ggplot2{ggplot}
object.
# For SingleCellExperiment object
library(TENxPBMCData)
library(scater)
tenx_pbmc3k <- TENxPBMCData(dataset = "pbmc3k")
rm_ind <- calculateAverage(tenx_pbmc3k) < 0.1
tenx_pbmc3k <- tenx_pbmc3k[!rm_ind, ]
tenx_pbmc3k <- logNormCounts(tenx_pbmc3k)
tenx_pbmc3k <- runPCA(tenx_pbmc3k)
tenx_pbmc3k <- make_hexbin(tenx_pbmc3k, 10, dimension_reduction = "PCA")
plot_hexbin_density(tenx_pbmc3k)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.