1
$\begingroup$

I am trying to fit some data with a function in Python; I have tried having only one free parameter (let's call this parameter "A"), and then using the same function but with two free parameters ("A" and "B") (I turn a fixed number into the free parameter "B"). I have then looked at the errors associated to the best-fit values printing the covariance matrix.

However, in the case of 2 free parameters I get an error (associated to the best-fit value for parameter "A") which is much bigger than in the case of the one-parameter fit.

Shouldn't it be the opposite case? If I am right expecting a smaller error in case of more parameters, do you have an idea of why I can get a bigger error with more parameters?

Thanks

$\endgroup$
1
  • $\begingroup$ Is this a non-linear fit? If so, the starting choices for the parameter values might send you to a local optimum that is not the global optimum. If that affected your 2-free-parameter model, its predictions could be poor. Plots of your data points and fits, and the forms of the equations, would help inform an answer. See this page for some examples of the problems that can arise from different choices of starting parameter values. $\endgroup$
    – EdM
    Commented Dec 30, 2019 at 19:39

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.