First of all, I am quite new to Julia and not at all an expert in either coding or optimization/modelling!
I want to calibate the following model with 2 parameters to calibrate (K[1] and K[2]) and 2 variables (X[1] and X[2]) (sorry for the bad restranscription)
Y = Y(0) x 4 x A / [(1+A)^2 x exp(B) -(1-A)^2 x exp(-B)]
With: A = ( K[1] / (K[1]+K[2]) )^(1/2) and B = ( K[1]+K[2] ) x A x X[1] x X[2]
I have 800+ conditions for which I would like to calibrate the parameters K of the model.
I have a lot of data for that, stored in a matrix.
How would you do it?
I have performed an optimization using the Optim library but the results are a bit “strange”. There seems to be a loss in the continuity when I plot the parameters vs the conditions:
If I understand your question correctl, I see at least two possibilities:
It could simply be that you need to run the optimization for more iterations – try decreasing your tolerances etc.
The optimization problem is likely to be nonconvex, so it may have multiple local optima that the optimization is jumping between as you vary the conditions (which local optimum an optimization routine finds can be hard to predict). To track a particular local optimum continuously, you can try to start the optimization using as an initial guess the values from the adjacent condition.
Hi everyone,
I implemented what you suggested Steven and I obtained the same results, it seems it’s coming from the data I have.
I have another question, I am struggling with the Optim toolbox. I am trying to add a condition for the two estimated parameters (they need to be positive) and to have an initialisation (initial guess).
I am quite lost in all the methods of the Optim that have their proper options.
I tried many things, such as the example below, but it does not seem to work: