predict_plot.lm: Plot predictors versus residuals.

View source: R/plot.R

predict_plot.lmR Documentation

Plot predictors versus residuals.

Description

Makes a matrix of pairwise scatterplots with lowess-type trend lines.

Usage

## S3 method for class 'lm'
predict_plot(object, data, partial = F, ylab = NULL, ...)

Arguments

object

the output of lm.

data

a data frame to use instead of model.frame(object).

partial

If TRUE, plot partial residuals instead of residuals.

ylab

axis label.

...

extra arguments for predict_plot.data.frame.

Details

Partial residuals are computed by fitting a new model with the predictor removed, which is different from residuals(type="partial").

Value

A plot similar to predict_plot, but where the vertical axis is residuals. These plots can be used to judge which predictors should be added to the model.

Author(s)

Tom Minka

See Also

predict_plot

Examples

# see the examples for predict_plot

paulemms/datamining documentation built on March 1, 2023, 4:01 p.m.