Closed juliangilbey closed 1 year ago
I think that makes sense, feel free to submit a PR!
I've just submitted a PR for this; I also realise that I got one of my suggested fixes wrong - it should have been i >= max_iter - 1
!
Thanks you for the PR, this will be published in the next release!
It seems that at this point: https://github.com/stanfordmlgroup/ngboost/blob/3a064b48b2f97ddc99bf01aa93d4037e466a67a8/ngboost/ngboost.py#L424-L425 the code breaks out of the loop once there are
max_iter+1
predictors rather thanmax_iter
, as the enumeration starts from 0. One easy way to fix this is to addstart=1
to the enumerate call; another is to test fori >= max_iter + 1
.