plsplot: Plot prediction graph for mvr model

Description Usage Arguments Examples

Description

Plot prediction graph using pls package's 'predplot' function but with ability to add statistical labeling

Usage

1

Arguments

...

pass on to predplot

mvr

mvr object (pls model)

ncomp

number of component

location

legend position

show

select statistics to show

round

digits to round

newx

newx

newy

newy

fitline

add fitline or not

cex.stats

text size of statistics legend

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
require(pls)
data(yarn)
model <- plsr(density ~ NIR, 6, data = yarn, validation = "CV")
plsplot(model) # calibration set result
plsplot(model, estimate = "CV") # cross validation set result

## customizing the graphs
plsplot(model, location = "topleft") # change legend position
plsplot(model, show = "R2") # show only R2
plsplot(model, show = "R2", round = 4) # round to four digits
plsplot(model, fitline = FALSE) # get rid of fitline
plsplot(model, show = "R2", cex.stats = 3) # bigger stats font
plsplot(model, cex.lab = 1.5, cex.main = 2) # bigger labels font

chengvt/cheng documentation built on May 13, 2019, 3:52 p.m.