I want to calculate Hosmer Lemeshow statistic for my multivariate logistic model. I tried both hosmerlem (command below) and hosmer.test functions.
hosmerlem(y= my binary dependent variable, yhat=fitted(my glm))
(The dependent variable for the logistic model is binary, and I included about 10 predictor variables.)
But in both cases, I keep getting this error: Error in quantile.default(yhat, probs = seq(0, 1, 1/g)) : missing values and NaN's not allowed if 'na.rm' is FALSE
Can someone please help ? Thanks in advance!