View source: R/hosmerlem_test.R
hosmerlem_test | R Documentation |
The Hosmer-Lemeshow test is a statistical test for goodness of fit for logistic regression models.
hosmerlem_test(mod, k = 10)
mod |
a model object created by |
k |
number of bins to use to calculate quantiles |
a dataframe
## Not run:
set.seed(43214)
x <- rnorm(100)
pr <- exp(x)/(1+exp(x))
y <- 1*(runif(100) < pr)
mod <- glm(y~x, family=binomial)
hosmerlem_test(mod, k = 10)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.