pubh (version 1.1.16)

logistic_gof: Goodness of fit for Logistic Regression.

Description

logistic_gof performs the Hosmer and Lemeshow test to test the goodness of fit of a logistic regression model. This function is part of residuals.lrm from package rms.

Usage

logistic_gof(model)

Arguments

model

A logistic regression model object.

References

Hosmer DW, Hosmer T, Lemeshow S, le Cessie S, Lemeshow S. A comparison of goodness-of-fit tests for the logistic regression model. Stat in Med 16:965<U+2013>980, 1997.

Examples

Run this code
# NOT RUN {
data(diet, package = "Epi")
model <- glm(chd ~ fibre, data = diet, family = binomial)
glm_coef(model, labels = c("Constant", "Fibre intake (g/day)"))
logistic_gof(model)
# }

Run the code above in your browser using DataLab