What are the reasons for sm.Logit to fail?
I tried at first with part of my data set set aside for testing and got this error.
model = sm.Logit(y,X).fit(method='lbfgs', max_iterations= 100000)
HessianInversionWarning: Inverting hessian failed, no bse or cov_params available
'available', HessianInversionWarning)
I tried again with difference solvers and with my whole dataset and got this message.
ConvergenceWarning: Maximum Likelihood optimization failed to converge. Check mle_retvals
"Check mle_retvals", ConvergenceWarning)
I tried stack overflow, but only found this question that is about when Y values are not 0 and 1, which mine are. Any suggestions? It is converging with sklearn's logistic regression.
https://stackoverflow.com/questions/20703733/logit-regression-and-singular-matrix-error-in-python