plotScores.pca | R Documentation |
Shows a scores plot for selected components.
## S3 method for class 'pca'
plotScores(
obj,
comp = if (obj$ncomp > 1) c(1, 2) else 1,
type = "p",
show.axes = TRUE,
show.legend = TRUE,
res = obj$res,
...
)
obj |
a PCA model (object of class |
comp |
a value or vector with several values - number of components to show the plot for |
type |
type of the plot ("p", "l", "b", "h") |
show.axes |
logical, show or not a axes lines crossing origin (0,0) |
show.legend |
logical, show or not a legend on the plot |
res |
list with result objects to show the variance for |
... |
other plot parameters (see |
If plot is created only for one result object (e.g. calibration set), then the behaviour and
all settings for the scores plot are identical to plotScores.ldecomp
. In this case
you can show scores as a scatter, line or bar plot for any number of components.
Otherwise (e.g. if model contains results for calibration and test set) the plot is a group
plot created using mdaplotg
method and only scatter plot can be used.
See examples in help for pca
function.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.