plot.quickPredict: Graphical Methods for quickPredict Objects

Description Usage Arguments Value Author(s) See Also Examples

View source: R/plotEtAlquickPredict.R

Description

plot, lines, image, contour and persp methods for quickPredict objects.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## S3 method for class 'quickPredict'
plot(x, y, xFct = function(x) x, style = c("band",
     "simple"), ylim, meanCol = 2, meanWD = 2, bandCol = "grey50", xlab,
     ylab, ...)
## S3 method for class 'quickPredict'
lines(x, what = c("mean", "upr", "lwr"),
      xFct = function(x) x, ...)
## S3 method for class 'quickPredict'
image(x, main, xlab, ylab, ...)
## S3 method for class 'quickPredict'
contour(x, what = c("mean", "sd"), main, xlab, ylab, add,
        ...)
## S3 method for class 'quickPredict'
persp(x, what = c("mean", "sd"), main, xlab, ylab, zlab, ...)

Arguments

x

a quickPredict object.

y

Not used but required by the plot method definition.

xFct

a function applied to the xx component of argument x which is itself a quickPredict object. Useful to get a plot with the "native" scale of the variable.

style

a character string, either "band" or "simple". Controls the way confidence intervals are displayed. If "band" is selected they are shown as a ribbon. Their boundaries appear as dashed lines otherwise.

ylim

see plot (default provided if missing).

meanCol

the color used to display the estimated mean of the term (see argument col in plot).

meanWD

the width used to display the estimated mean of the term (see argument lwd in plot).

bandCol

the color of the confidence interval ribbon when one is is drawn.

xlab, ylab, zlab

see plot and persp (default provided if any is missing).

main

see image, contour and persp (default provided if missing).

what

for lines.quickPredict, one of the following character strings: "mean", "upr", "lwr". Controls the line drawn: the estimated mean, upper bound of the 95% CI or lower bound. For contour.quickPredict and persp.quickPredict, a character string specifying if the mean or the sd contours or surface should be drawn.

add

see contour.

...

additional arguments to plot, lines, image, contour and persp.

Value

Nothing returned, these functions are used for their side effects: plots are generated or modified.

Author(s)

Christophe Pouzat christophe.pouzat@gmail.com

See Also

quickPredict, plot, lines image, contour, persp, plot.ssanova

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
## Not run: 
## Follow up of ssanova example of gss
data(nox)
nox.fit <- ssanova(log10(nox)~comp*equi,data=nox)
## get prediction for the first term, comp
comp.pred <- quickPredict(nox.fit)
## plot result with method plot for quickPredict objects
plot(comp.pred)
## get prediction for the second term, equi using the binary version
equi.pred <- nox.fit 
plot(equi.pred)
## get prediction for the interaction term, comp:equi
comp.equi.pred <- nox.fit 
## use image method image
image(comp.equi.pred)
## use contour method
contour(comp.equi.pred,col=2,lwd=2,labcex=1.5)
contour(comp.equi.pred,what="sd",lty=3,labcex=1.2,add=TRUE)
## use persp method
persp(comp.equi.pred,theta=-10,phi=20)

## End(Not run)

STAR documentation built on May 2, 2019, 11:44 a.m.