Description Usage Arguments Details Value Examples
Beeswarm plot of the latent factor values.
1 2 3 | plotFactorBeeswarm(object, factors = "all", color_by = NULL,
shape_by = NULL, name_color = "", name_shape = "",
showMissing = FALSE)
|
object |
a trained |
factors |
character vector with the factor name(s), or numeric vector with the index of the factor(s) to use. Default is 'all' |
color_by |
specifies groups or values used to color the samples.
This can be either:
a character giving the name of a feature,
a character giving the same of a covariate (only if using |
shape_by |
specifies groups or values used for the shape of samples. See color_by for how this can be specified. A maximum of 6 different values can be specified. |
name_color |
name for color legend (usually only used if color_by is not a character itself) |
name_shape |
name for shape legend (usually only used if shape_by is not a character itself) |
showMissing |
logical indicating whether to remove samples
for which |
One of the main steps for the annotation of factors is
to visualise and color them using known covariates or phenotypic data.
This function generates a Beeswarm plot of the sample values in a given latent factor.
Similar functions are plotFactorScatter
for doing scatter plots and
plotFactorHist
for doing histogram plots
Returns a ggplot2
object
1 2 3 4 5 6 7 8 9 10 | # Example on the CLL data
filepath <- system.file("extdata", "CLL_model.hdf5", package = "MOFAdata")
MOFA_CLL <- loadModel(filepath)
plotFactorBeeswarm(MOFA_CLL, factors=1:3)
plotFactorBeeswarm(MOFA_CLL, factors=1:2, color_by= "IGHV")
# Example on the scMT data
filepath <- system.file("extdata", "scMT_model.hdf5", package = "MOFAdata")
MOFA_scMT <- loadModel(filepath)
plotFactorBeeswarm(MOFA_scMT)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.