plot_pls_indepPred | R Documentation |
Use independent data for predictions in the pls-models within the cube and plot those predictions and, if available, the validation data.
plot_pls_indepPred(
indepDataset,
cube,
cnv = NULL,
inv = NULL,
psd = "def",
aps = "def",
pl = TRUE,
toxls = "def",
...
)
indepDataset |
The dataset containing the independent data. An object
of class 'aquap_data' as produced by |
cube |
An object of class 'aquap_cube' as produced by |
cnv |
"Cube numeric variable", character vector or NULL. The names of
one or more numeric variables in the cube on which models have been
calculated. Leave at the default NULL to use all of the numeric
variables on which a plsr model has been calculated, or provide a character
vector with valid variable names for a sub-selection. For the selected
variables, predictions from the data in the independent dataset will be made.
If argument |
inv |
"Independent numeric variable", character vector or NULL. The names
of numeric variables in the independent dataset. If left at the default
NULL, numerical variables in the independent dataset with exactly the same
name(s) as specified in argument |
psd |
'plot secondary data'; either character 'def' or logical. If
secondary (i.e.crossvalidation data) should be plotted as well. Leave at the
default 'def' to take the value from the parameter
|
aps |
Character length one. The default way to obtain the analysis procedure. Defaults to "def". Possible values are:
|
pl |
Logical, defaults to TRUE. If predicted data should be plotted at all. If FALSE, only the calculation and the (possible) export to an excel file (see details) will be performed. |
toxls |
'def' or logical. If left at the default 'def' the value from
|
... |
Arguments for overriding one or more of the plotting parameters
from the analysis procedure, please see |
Please see the documentation for the single parameters (cnv
and inv
) to see how the selection of the available models and the
selection of possibly available data for validation is handled. For coloring,
the argument pls.colorBy
of the analysis procedure can be used, but
here the data for the colors are selected from the independent
dataset. If the parameter plsr_indepPred_exportToExcel
in the
settings file is set to TRUE, the results are exported to an excel file in the
results folder as well.
An (invisible) list containing the numerical results of the
predictions, and if parameter plsr_indepPred_exportToExcel
in the
settings file is set to TRUE, these data are exported to an excel file in the
results folder as well.
Other PLSR documentation:
calc_pls_args
,
plot_pls,aquap_cube-method
,
plot_pls_args
Other Plot functions:
plot,aquap_cube,missing-method
,
plot,aquap_data,missing-method
,
plot_aqg()
,
plot_classifX_indepPred()
,
plot_da,aquap_cube-method
,
plot_nnet,aquap_cube-method
,
plot_pca,aquap_cube-method
,
plot_pls,aquap_cube-method
,
plot_rnf,aquap_cube-method
,
plot_simca,aquap_cube-method
,
plot_svm,aquap_cube-method
## Not run:
fd <- gfd()
cu <- gdmm(fd) # assumes that you have plsr enabled in the analysis procedure
fdIndep <- fd # !!!pretend!!! that fdIndep is now an other, independent dataset
predList <- plot_pls_indepPred(fdIndep, cu)
predList <- plot_pls_indepPred(fdIndep, cu, cnv="Y_Temp") # to only use the
# models regressed on 'Y_Temp'
predList <- plot_pls_indepPred(fdIndep, cu, cnv="Y_Temp", inv="Y_fooBar")
# to only use the models regressed on 'Y_Temp', and use the numeric variable
# 'Y_fooBar' from the independent dataset for validation
predList <- plot_pls_indepPred(fdIndep, cu, aps="fooBar.r") # use the values
from the analysis procedure file 'fooBar.r' for plotting
predList <- plot_pls_indepPred(fdIndep, cu, pl=FALSE) # no plotting, just
# calculation and possible export to excel.
predList <- plot_pls_indepPred(fdIndep, cu, pls.colorBy="C_Group") # use the
# class variable 'C_Group' from the independent dataset for coloring
predList <- plot_pls_indepPred(fdIndep, cu, pg.where="pdf", pg.fns="_fooBar")
# add the string '_fooBar' to the generated pdfs.
predList <- plot_pls_indepPred(fdIndep, cu, toxls=FALSE) # no exporting to xls
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.