You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I attempted to use curve_fit from LsqFit.jl on data stored in a DataFrame column, as in curve_fit(model, df[:x], df[:y], p0). This produced the following error:
Of course this is easily resolved by explicitly converting the inputs to Arrays, but it's a bit cumbersome. I'm pretty new to Julia and its type system, but from looking at the code there's no obvious reason to me why finite_difference_jacobian! couldn't work with its signature changed to use AbstractArray and AbstractVector, relieving the need to convert DataArrays. Is this reasonable? If there's no reason not to do it, I can try to test it out and make a pull request when I have time.
The text was updated successfully, but these errors were encountered:
Generalizing this would make sense. It unfortunately will mean that the code tries to write into immutable AbstractArray objects (e.g. Range), but the increase in generic programming probably makes up for the decrease in useful compile-time errors.
I attempted to use
curve_fit
fromLsqFit.jl
on data stored in aDataFrame
column, as incurve_fit(model, df[:x], df[:y], p0)
. This produced the following error:Of course this is easily resolved by explicitly converting the inputs to
Array
s, but it's a bit cumbersome. I'm pretty new to Julia and its type system, but from looking at the code there's no obvious reason to me whyfinite_difference_jacobian!
couldn't work with its signature changed to useAbstractArray
andAbstractVector
, relieving the need to convertDataArray
s. Is this reasonable? If there's no reason not to do it, I can try to test it out and make a pull request when I have time.The text was updated successfully, but these errors were encountered: