Logistic regression - hosmer lamselow goodness of fit

#1
Greetings

I run a binary logistic regression. I try to choose among many many covariates I have these that are possible confounders and when building the regression line I think I tried to make a good coverage of these confounders and relevant covariates.


I run the same regression for few test for few dichotomic variables I have at different levels as these are my variables of interest.

My Nagel-Kerke R^2 is somewhere around 0.36 and for the omnibus test the model is significant. Yet the model is significant in the Homser and Lemeshow test. I can play along some covariates so the model would fit better according to this measure and then the Hom-Lem would not be significant but for the next regression I need to run with the same covariates but for the independent variable of my interest the Hom-Lem is again significant - I'm afraid I have no fully adjused model I can get with Hom-Lem insignifcant. Yet other parameters as I understand them indicate the model is reasonble.

Is significant H-L test makes the model irrelevant? or not reliable to the extent it can't be published?

edit: my sample is around 4400, out o fit 160 account positive (in the dependent outcome)

regards

David
 
Last edited:

hlsmith

Less is more. Stay pure. Stay poor.
#2
R^2 is a weird metric for logistic regression and many people opt not to use it. In lieu of a formal H-L test I would plot the calibration curve to understand fit and predictive value.
 

fed2

Active Member
#3
hosmer lemeshow is a goodness of fit test. if it is significant it indicates your fit is not good. you can use you eyeballs to see how close the observed and expected are by plotting.
 

hlsmith

Less is more. Stay pure. Stay poor.
#4
hosmer lemeshow is a goodness of fit test. if it is significant it indicates your fit is not good. you can use you eyeballs to see how close the observed and expected are by plotting.
Yeah, the calibration plot is a visualization for this. And you can slap confidence intervals on it and add a rug (plot) on the X-axis.