31 Mar
2008
31 Mar
'08
7:07 p.m.
I have as my fitting function a system of differential equations(3) and I am supposed to get the optimal parameters to use by fitting data to this system. I tried to use scipy.optimize.leastsq. The difficulty is with the function that calculates the difference between the data and the values from the fitting function. The result of the fitting function is a list with three values and yet I only need one of the values to be subtracted from the data value. Could you not just subtract the index of the returned value? Say it is the first value you need then just use value[0].
If not can you give a small example, it will make it easier to help. Gabriel