ceres.plots {car} | R Documentation |
These functions calculate Ceres plots for linear and generalized linear model.
ceres.plots(model, variable, ask=missing(variable), one.page=!ask, span=0.5, ...) ceres.plot(model, ...) ## S3 method for class 'lm': ceres.plot(model, variable, line=TRUE, smooth=TRUE, span=0.5, iter, las=par('las'), col=palette()[2], pch=1, lwd=2, main="Ceres Plot", ...) ## S3 method for class 'glm': ceres.plot(model, ...)
model |
model object produced by lm or glm . |
variable |
variable (if it exists in the search path) or
name of variable. This argument usually is omitted for
ceres.plots . |
ask |
if TRUE , a menu is provided in the R Console for the
user to select the variable(s) to plot, and to modify the span for the smoother
used to draw a nonparametric-regression line on the plot. |
one.page |
if TRUE (and ask=FALSE ), put all plots on one
graph. |
span |
span for lowess smoother. |
iter |
number of robustness iterations for nonparametric-regression smooth; defaults to 3 for a linear model and to 0 for a non-Gaussian glm. |
line |
TRUE to plot least-squares line. |
smooth |
TRUE to plot nonparametric-regression (lowess) line. |
las |
if 0 , ticks labels are drawn parallel to the
axis; set to 1 for horizontal labels (see par ). |
col |
color for points and lines; the default is the second entry
in the current color palette (see palette
and par ). |
pch |
plotting character for points; default is 1
(a circle, see par ). |
lwd |
line width; default is 2 (see par ). |
main |
title for plot. |
... |
pass arguments down. |
Ceres plots are a generalization of component+residual (partial residual) plots that are less prone to leakage of nonlinearity among the predictors.
The function intended for direct use is ceres.plots
.
By default, this function is used interactively
through a text menu.
The model cannot contain interactions, but can contain factors. Factors may be present in the model, but Ceres plots cannot be drawn for them.
NULL
. These functions are used for their side effect: producing
plots.
John Fox jfox@mcmaster.ca
Cook, R. D. and Weisberg, S. (1999) Applied Regression, Including Computing and Graphics. Wiley.
Fox, J. (1997) Applied Regression, Linear Models, and Related Methods. Sage.
## Not run: ceres.plots(lm(prestige~income+education+type, data=Prestige)) ## End(Not run)