Learn R Programming

olsrr (version 0.6.0)

ols_pred_rsq: Predicted rsquare

Description

Use predicted rsquared to determine how well the model predicts responses for new observations. Larger values of predicted R2 indicate models of greater predictive ability.

Usage

ols_pred_rsq(model)

Value

Predicted rsquare of the model.

Arguments

model

An object of class lm.

See Also

Other influence measures: ols_hadi(), ols_leverage(), ols_press()

Examples

Run this code
model <- lm(mpg ~ disp + hp + wt + qsec, data = mtcars)
ols_pred_rsq(model)

Run the code above in your browser using DataLab