Whaley Vega Question

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Whaley Vega Question

Tom Hafner
Hello,

First off, thank you so much for putting in the obvious effort required to
pull off a project of this scope.  Thank you!

But down to business, I've downloaded and installed the XL addin.  I am
trying to obtain a function (or even just a formula to code my own function,
if need be) which would give me the vega (and later the gamma, delta, and
theta) of an American option under the Barone-Adesi/Whaley model.

So I opened the file, c:\Program
Files\QuantLibXL-0.8.0\Workbooks\StandaloneExamples\options.xls and took a
peek around.

The formula in cell F6 on the "vanilla" tab seems to give the fair value of
the option.  It looks like if I replace "qlInstrumentNPV" in that formula
with "qlInstrumentResults", then I ought to be able to see the vega of the
option ("ResultType e.g. 'vega'." from qlInstrumentResults function
arguments dialog box).  But I couldn't get that to work.  I just got #NUM!
or #VALUE!

I couldn't find any sort of of help files, either.

Do you think you could either instruct me on how to access a detailed help
file, listing function usage, or perhaps just point me in the direction of
some source code, from which I could glean the underlying formulae?

I found this email address (qu**[hidden email]) at
http://quantlib.org/quantlibxl/installation.html.  But I am not subscribed
to the listserv, so you may have to respond to me directly at
t_hafner@hotm**l.com  I don't know.

Thanks,
--Tom.

_________________________________________________________________
Booking a flight? Know when to buy with airfare predictions on MSN Travel.
http://travel.msn.com/Articles/aboutfarecast.aspx&ocid=T001MSN25A07001


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Reply | Threaded
Open this post in threaded view
|

Re: Whaley Vega Question

eric ehlers
Hi Tom,

On 8/5/07, Tom Hafner <[hidden email]> wrote:
> Hello,
>
> First off, thank you so much for putting in the obvious effort required to
> pull off a project of this scope.  Thank you!

:-) You're welcome on behalf of
http://quantlib.org/reference/group.html
http://www.quantlibxl.org/people.html

> But down to business, I've downloaded and installed the XL addin.  I am
> trying to obtain a function (or even just a formula to code my own function,
> if need be) which would give me the vega (and later the gamma, delta, and
> theta) of an American option under the Barone-Adesi/Whaley model.
>
> So I opened the file, c:\Program
> Files\QuantLibXL-0.8.0\Workbooks\StandaloneExamples\options.xls and took a
> peek around.
>
> The formula in cell F6 on the "vanilla" tab seems to give the fair value of
> the option.  It looks like if I replace "qlInstrumentNPV" in that formula
> with "qlInstrumentResults", then I ought to be able to see the vega of the
> option ("ResultType e.g. 'vega'." from qlInstrumentResults function
> arguments dialog box).  But I couldn't get that to work.  I just got #NUM!
> or #VALUE!

That operation, qlInstrumentResults, is supported to varying degrees
by different instrument classes and looks to me to be totally
unsupported in this case.  Instead you can use qlVega() and examples
of this appear in the sheet "options" in the same workbook.

When a function returns #VALUE, it means that you entered the wrong
number of arguments, or arguments of the wrong type.  When a function
returns #NUM then an error occurred within QuantLib which can be
retrieved e.g. with ohRetrieveError().

> I couldn't find any sort of of help files, either.
>
> Do you think you could either instruct me on how to access a detailed help
> file, listing function usage,

Have a look at QuantLibXL-0.8.0\Docs\QuantLibXL-docs-0.8.0.chm.

> or perhaps just point me in the direction of
> some source code, from which I could glean the underlying formulae?

http://quantlib.org/quantlibaddin/build_tutorial.html

Regards,
Eric

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users