Learn R Programming

performance (version 0.8.0)

r2_nagelkerke: Nagelkerke's R2

Description

Calculate Nagelkerke's pseudo-R2.

Usage

r2_nagelkerke(model, ...)

Arguments

model

A generalized linear model, including cumulative links resp. multinomial models.

...

Currently not used.

Value

A named vector with the R2 value.

References

Nagelkerke, N. J. (1991). A note on a general definition of the coefficient of determination. Biometrika, 78(3), 691-692.

Examples

Run this code
# NOT RUN {
model <- glm(vs ~ wt + mpg, data = mtcars, family = "binomial")
r2_nagelkerke(model)
# }

Run the code above in your browser using DataLab