plot.mbl {resemble} | R Documentation |
mbl
Plots the content of an object of class mbl
## S3 method for class 'mbl' plot(x, g = c("validation", "pca"), param = "rmse", pcs = c(1,2), ...)
x |
an object of class |
g |
a character |
param |
one of the following options "rmse", "st.rmse" or "r2". The respective validation statistic is then plotted. It is only available if |
pcs |
a vector of length one or two indicating the principal components to be plotted. Default is |
... |
some arguments to be passed to methods as graphical parameters. |
Leonardo Ramirez-Lopez and Antoine Stevens
## Not run: require(prospectr) data(NIRsoil) Xu <- NIRsoil$spc[!as.logical(NIRsoil$train),] Yu <- NIRsoil$CEC[!as.logical(NIRsoil$train)] Yr <- NIRsoil$CEC[as.logical(NIRsoil$train)] Xr <- NIRsoil$spc[as.logical(NIRsoil$train),] Xu <- Xu[!is.na(Yu),] Yu <- Yu[!is.na(Yu)] Xr <- Xr[!is.na(Yr),] Yr <- Yr[!is.na(Yr)] ctrl <- mblControl(sm = "cor", ws = 51, pcSelection = list("cumvar", 0.999), valMethod = c("NNv"), scaled = TRUE, center = TRUE) ex1 <- mbl(Yr = Yr, Xr = Xr, Yu = NULL, Xu = Xu, mblCtrl = ctrl, dissUsage = "none", k = seq(30, 250, 30), method = "wapls1", plsC = c(7, 20)) plot(ex1) ## End(Not run)