Usage
plotExplanatoryVariables(object, method = "density", exprs_values = "exprs", nvars_to_plot = 10, min_marginal_r2 = 0, variables = NULL, return_object = FALSE, theme_size = 10, ...)
Arguments
object
an SCESet object containing expression values and
experimental information. Must have been appropriately prepared.
method
character scalar indicating the type of plot to produce. If
"density", the function produces a density plot of R-squared values for each
variable when fitted as the only explanatory variable in a linear model. If
"pairs", then the function produces a pairs plot of the explanatory variables
ordered by the percentage of feature expression variance (as measured by
R-squared in a marginal linear model) explained.
exprs_values
which slot of the assayData
in the object
should be used to define expression? Valid options are "exprs" (default),
"tpm", "fpkm", "cpm", and "counts".
nvars_to_plot
integer, the number of variables to plot in the pairs
plot. Default value is 10.
min_marginal_r2
numeric scalar giving the minimal value required for
median marginal R-squared for a variable to be plotted. Only variables with a
median marginal R-squared strictly larger than this value will be plotted.
variables
optional character vector giving the variables to be plotted.
Default is NULL
, in which case all variables in pData(object)
are considered and the nvars_to_plot
variables with the highest median
marginal R-squared are plotted.
return_object
logical, should an SCESet
object with median
marginal R-squared values added to varMetadata(object)
be returned?
theme_size
numeric scalar giving font size to use for the plotting
theme
...
parameters to be passed to pairs
.