Dear Moeti Ncube
Thanks for your code, it does help me a lot!
But I have a question for results.
In general, the simulated price should be very close to the Heston model price, right?
But why it seem that there is a gap between "simhes" and "modhes"?
In Heston model, If the parameters obey 2*kappa*theta> sig (known as the Feller condition) then the process volatility is strictly positive. When I run your codes even using your marketdata, calibrated parameters violate the feller condition. Could you please explain why it is so and probably fix it if possible.
Thanks in advance
Hey every one I am trying to run this code as it is but I get the message " Undefined function 'lsqnonlin' for input arguments of type'function_handle'.
Error in hestoncalibrationexample (line 36)
x = lsqnonlin(@costf2,x0,lb,ub);
Any body can help me with this problem?
thanks in advance