# How well does my logistic regression model fit?

I performed a logistic regression to my dataset which has 6 variables. I got output from R as the following:

I used the step() function in R to select the best model, and above is my best model. The AIC value is so high! Could someone help me to explain how well does my model fit based on this information on the figure? If additional information is needed, what do I need to calculate?

BTW, how to calculate $R^2$ for my model?

Thanks,

The absolute AIC value is meaningless. AIC is calculated by different methods only up to a constant. Thus, AIC can only be compared between models, and models fitted by the same piece of software.

Better: assess the predictive power of your predicted probabilities in a holdout sample. Don't use accuracy, use scoring rules or similar.

Could someone help me to explain how well is my model fit based on this information on the figure.

It depends on how you define what a good model fit is. You could mean whether the assumptions of the model are valid. It is hard to say from the figure. Various things could be wrong with the model. E.g.,

1. Is it the right link function?
2. Are there interactions which you did not include (you only used main effects by ~ .).
3. Are the effects linear or are there non-linear effects for some of continuous predictors?

You likely need to look at text books if you have not worked much with GLMs before. You can check this question for GLM books.

The AIC value is so high!

If you mean high relative to the other models you have fitted then this is not surprising since step optimize the AIC if I remember correctly. You cannot judge the model fit from the AIC as Stephan Kolassa mentions. You can only use the value to compare with other models fitted on the same data.

BTW, how to calculate $R^2$ for my model?

There is no $R^2$ for GLMs but there are various suggested alternativs. See this wiki page.