MBplotBlocks {MBAnalysis} | R Documentation |
Customizable plots of blocks related information
Description
Plots blocks related information of MBPCA
, ComDim
, MBPLS
or MBWCov
with several options of customization.
Usage
MBplotBlocks(
res,
which = "explained.blocks&Y",
axes = c(1, 2),
blocks.axes = 1:max(axes),
title = NULL,
size = 2.25
)
Arguments
res |
|
which |
Either "explained.blocks&Y", "scree", "structure" or "blocks.axes". See details. |
axes |
Which global dimensions should be plotted? Only useful if which=structure or which=blocks.axes |
blocks.axes |
Which individual blocks dimensions should be correlated with global ones? Only useful if which=blocks.axes |
title |
An optional title to be added to the plot. |
size |
The overall size of labels, points, etc. |
Details
-
explained.blocks&Y: Barplot of the percentages of inertia explained in each block of variables (and Y for
MBPLS
orMBWCov
) by each global components. -
scree: Barplot of the saliences of each block of variables on each global components.
-
structure: Blocks coordinates (saliences) on the global selected axes
-
blocks.axes: Correlations of the selected individual blocks.axes with the global selected axes.
Value
The required plot.
See Also
plot.MBPCA
plot.ComDim
plot.MBPLS
plot.MBWCov
Examples
# Unsupervised example
data(ham)
X=ham$X
block=ham$block
res.mbpca <- MBPCA(X,block, name.block=names(block))
MBplotBlocks(res.mbpca,which="explained.blocks&Y")
MBplotBlocks(res.mbpca,which="scree")
MBplotBlocks(res.mbpca,which="structure")
MBplotBlocks(res.mbpca,which="blocks.axes")
# Supervised example
data(ham)
X=ham$X
block=ham$block
Y=ham$Y
res.mbpls <- MBPLS(X, Y, block, name.block=names(block))
MBplotBlocks(res.mbpls,which="explained.blocks&Y")
MBplotBlocks(res.mbpls,which="scree")
MBplotBlocks(res.mbpls,which="structure")
MBplotBlocks(res.mbpls,which="blocks.axes")