Skip to content

Pr/3923 #4187

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 23, 2014
Merged

Pr/3923 #4187

merged 2 commits into from
Nov 23, 2014

Conversation

ev-br
Copy link
Member

@ev-br ev-br commented Nov 23, 2014

this is a suggested redo of gh-3923: this adds a check_finite flag to curve_fit, modelled after a similar flag in linalg. IMO having this flag is a reasonable price to pay for fixing the nonsense of gh-3422, but apparently, there is a range of opinions, see gh-3923 for discussion.

I think it would be nice to fix the original issue, gh-3422, for 0.15.
This PR and gh-3925 provide slightly different ways of fixing it, and I personally would be fine with either of them.

And yeah, in case this is decided to be the one to be merged, github magic: closes gh-3923, fixes gh-3422

otizonaizit and others added 2 commits November 22, 2014 23:43
curve_fit now raises ValueError if input data contains NaNs.
Previously curve_fit would return nonsensical results.
@ev-br ev-br added this to the 0.15.0 milestone Nov 23, 2014
pv added a commit that referenced this pull request Nov 23, 2014
ENH: optimize: handle NaNs in curve_fit
@pv pv merged commit 45e9bab into scipy:master Nov 23, 2014
@pv
Copy link
Member

pv commented Nov 23, 2014

LGTM, this should be ok

@ev-br ev-br deleted the pr/3923_ branch November 24, 2014 08:06
@ev-br ev-br modified the milestone: 0.15.0 Nov 24, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

optimize.curve_fit() handles NaN by returning all parameters as 1.0
4 participants