Overlays the loadings of the selected proteins on the scatter of two components of a sPLS-DA.
plot.sPLSDA.biplot(
DEprot.sPLSDA.object,
comp.x = 1,
comp.y = 2,
color.column = NULL,
shape.column = NULL,
label.column = NULL,
ellipse = FALSE,
ellipse.level = 0.95,
plot.zero.line.x = TRUE,
plot.zero.line.y = TRUE,
n.loadings = 10,
loading.color = "turquoise4",
loading.arrow.size = 0.6,
loading.label.size = 3,
loading.alpha = 0.7,
loading.scale = 0.8
)An object of class DEprot.sPLSDA.
Number indicating which component to display on the x-axis. Default: 1.
Number indicating which component to display on the y-axis. Default: 2.
String indicating the name of the column in the metadata to use as factor for the dot colors. Default: NULL (the column used to fit the model).
String indicating the name of the column in the metadata to use as factor for the dot shapes. Default: NULL (all dots).
String indicating the name of the column in the metadata to use as label of the dots. Default: NULL (no labeling).
Logical value indicating whether a confidence ellipse should be drawn around each group. Default: FALSE.
Numeric value (0-1) indicating the confidence level of the ellipses. Default: 0.95.
Logical value to indicate whether to plot a gray dashed line in correspondence of x=0. Default: TRUE.
Logical value to indicate whether to plot a gray dashed line in correspondence of y=0. Default: TRUE.
Number of proteins to display, ranked by their distance from the origin in the plane displayed. Default: 10.
String indicating the color of the arrows and of their labels. Default: "turquoise4".
Numeric value indicating the linewidth of the arrows. Default: 0.6.
Numeric value indicating the font size of the labels. Default: 3.
Numeric value (0-1) indicating the transparency of arrows and labels. Default: 0.7.
Numeric multiplier to manually adjust the length of the arrows. Default: 0.8.
A ggplot object.
Only the proteins retained on at least one of the two components displayed can appear: a protein dropped by the sparsity penalty has a coefficient of exactly zero and no direction to point to.
splsda <- perform.sPLSDA(DEprot.object = DEprot::test.toolbox$dpo.imp,
group.column = "condition",
keepX = 5,
validate = FALSE)
#> Warning: The number of 'folds' (5) is larger than the smallest class (4 samples): 'folds' has been set to 4.
plot.sPLSDA.biplot(DEprot.sPLSDA.object = splsda,
comp.x = 1,
comp.y = 2,
n.loadings = 5)