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 am a big fan of both LsqFit.jl and the python package LMFIT.
I made a small wrapper-interface for LsqFit.jl to implement the Parameter functionality of LMFIT, to make the definition of fit-parameters more verbose (e.g. setting min/max values, and toggle if the parameter should be varied),
and maybe other people are interested to use something like this.
Is there any interest to add this interface to LsqFit? Or maybe create a dedicated julia-package?
I use it a follows:
using LMFit
f =2.45
φ =0.8model(x, f, φ) =sin.(x .* f .+ φ)
x =0:0.1:6pi
y =model(x, f, φ) .+0.04.*randn(length(x))
params = [
Param(name=:φ, value=0.9, min=0, max=255, vary=true),
Param(name=:f, value=2.5, min=0, max=255, vary=true),
]
out =curve_fit(model, x , y, params)
@infofitreport(out)
┌ Info: [[Variables]]
│ f:2.449846120404491±0.0007845311171137703 ( 0.03%) (init =2.5)
└ φ: 0.7936258619873663±0.008547481398733708 ( 1.08%) (init =0.9)
I'm happy with any decision 🙂
The text was updated successfully, but these errors were encountered:
I see. So you would like to be able to define individual parameters, their domain, and whether they should be optimized or not, rather than just a vector?
Yes indeed, I find it useful for prototyping or when I am testing several (slightly different) model.
On the other hand, I came across GModelFit which has similar functionality (see example) which uses LsqFit.jl as a base.
Maybe this is the cleaner option...
(I haven't used GModelFit yet though)
I am a big fan of both LsqFit.jl and the python package LMFIT.
I made a small wrapper-interface for LsqFit.jl to implement the
Parameter
functionality of LMFIT, to make the definition of fit-parameters more verbose (e.g. settingmin
/max
values, and toggle if the parameter should be varied),and maybe other people are interested to use something like this.
Is there any interest to add this interface to LsqFit? Or maybe create a dedicated julia-package?
I use it a follows:
I'm happy with any decision 🙂
The text was updated successfully, but these errors were encountered: