biplotPLS | R Documentation |
Makes a biplot of a fitted object (e.g. from a MUVR with PLS core).
biplotPLS(
fit,
comps = 1:2,
xCol,
labPlSc = TRUE,
labs,
vars,
labPlLo = TRUE,
pchSc = 16,
colSc,
colLo = 2,
supLeg = FALSE
)
fit |
A PLS fit (e.g. from MUVRclassObject$Fit[[2]]) |
comps |
Which components to plot |
xCol |
(Optional) Continuous vector for grey scale gradient of observation (sample) color (e.g. Y vector in regression analysis) |
labPlSc |
Boolean to plot observation (sample) names (defaults to TRUE) |
labs |
(Optional) Label names |
vars |
Which variables to plot (names in rownames(loadings)) |
labPlLo |
Boolean to plot variable names (defaults to TRUE) |
pchSc |
Plotting character for observation scores |
colSc |
Colors for observation scores (only if xCol omitted) |
colLo |
Colors for variable loadings (defaults to red) |
supLeg |
Boolean for whether to suppress legends |
A PLS biplot
data("freelive2")
nRep <- 2 # Number of MUVR2 repetitions
nOuter <- 3 # Number of outer cross-validation segments
varRatio <- 0.75 # Proportion of variables kept per iteration
method <- 'PLS' # Selected core modeling algorithm
regrModel <- MUVR2(X = XRVIP2,
Y = YR2,
nRep = nRep,
nOuter = nOuter,
method = method,
modReturn = TRUE)
biplotPLS(regrModel$Fit[[2]],
comps = 1:2,
xCol = YR2,
labPlSc = FALSE,
labPlLo = FALSE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.