• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

EXCEL VBA AND HESTON OPTION PRICING

Satyaprakash

New Member
I have the codes exactly as the book -Option pricing models and volatility using excel-vba has but I am getting a value error. Can someone please help me. Its very urgent!
 

Attachments

  • HEston final.xlsm
    29.5 KB · Views: 42
Hi Satyaprakash ,

I don't think this is deserved , but still ....

You have not defined the variable thePI ; secondly , I had changed the loop limits of the loop within the TRAPnumint function to :

1 to (n - 1)

Make these changes and the error should go away.

Narayan
 
OMG! Sory Narayan... That was the wrong file...In my hurry I posted it. Here is the one...The problem is that I am getting an answer that is much different... I am not able to find out if its a VBA issue or a mathematical issue because I have got all the codes right as per the book. Sorry again.
 
Hi Satyaprakash ,

While others go through the uploaded file , is it possible for you to go through the procedures which implement the complex number operations ( Addition , Subtraction , Multiplication , Division , Exponentiation and some more ) and confirm that they are working correctly ?

Confirming the main functions will probably take time if someone has to go through the mathematics !

Narayan
 
Hi Satyaprakash ,

Another thing about your model , can you check this website for its online calculator ?

http://optioncalculator.altervista.org/

The parameters mentioned there are just 9 , as follows :

Underlying Asset Price
Exercise Price
Time to Maturity
Correlation Parameter
Interest Rate
Mean Reversion Rate
Long run Variance
Initial Variance
Volatility of Variance

Your model has 10.

Can you see which of the above parameters corresponds to which in your model , put in the same values in both models and see the results you get ?

Narayan
 
Back
Top