Posted by
Luigi Ballabio on
Aug 13, 2013; 2:15pm
URL: http://quantlib.414.s1.nabble.com/Vanilla-American-Option-Pricing-tp14486p14496.html
Hello Sachin,
1) the assumption of constant vol is made in the example but can be
relaxed. When instantiating the BlackScholesProcess instance, you can
pass a BlackVarianceCurve instance if you're given at-the-money
volatilies at different maturities, or a BlackVarianceSurface instance
if you're given volatilities for different maturities and strikes.
Both classes are in the ql/termstructures/volatility/equityfx folder.
2) Calculation of implied Black volatility is implemented in the
impliedVolatility() method of VanillaOption. What other calculation
did you have in mind?
3) The option and term structure classes would in principle support
intraday calculation, but the Date class doesn't have a time part.
Adding a time data member to Date and modifying the DayCounter class
so that it takes it into account might do the trick (the day counters
are responsible for converting into time the distance between two
dates, such as the current evaluation date and the maturity date). Let
me know if it works.
Later,
Luigi
On Wed, Aug 7, 2013 at 5:05 PM, Sachin Kumar <
[hidden email]> wrote:
> Greetings,
>
> Like others here, I'm new to QuantLib. I'm interested in implementing a
> vanilla american option pricing methodology with QuantLib.
>
> The option will be an OCC listed option, overlying a large company like IBM
> (may or may not pay discrete dividends, but will not have a continuous
> dividend yield).
>
> I've reviewed the example found in EquityOption.cpp. Unfortunately, this
> departs from what I need in the following ways:
>
> 1. Assumption of a constant black-scholes volatility term-structure. I
> understand that using a LocalVolCurve term-structure might be what I'm
> looking for here, but I'm not sure.
>
> 2. Related to (1) is how one goes about implementing their own implied
> volatility calculation given market data.
>
> 3. Time to maturity resolution. I've read on other posts that QuantLib
> currently doesn't support intraday time, i.e. time to maturity that's less
> than 1 day. Given that I require this, I suspect I may need to create my own
> class hierarchy that mirrors the 1-day resolution classes. Is there any
> other way around this? If not, which classes would I need to mirror and
> re-implement?
>
> Any insight here is appreciated.
>
>
> Thanks!
>
> ------------------------------------------------------------------------------
> Get 100% visibility into Java/.NET code with AppDynamics Lite!
> It's a free troubleshooting tool designed for production.
> Get down to code-level detail for bottlenecks, with <2% overhead.
> Download for free and get started troubleshooting in minutes.
>
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk> _______________________________________________
> QuantLib-users mailing list
>
[hidden email]
>
https://lists.sourceforge.net/lists/listinfo/quantlib-users>
--
<
https://implementingquantlib.blogspot.com>
<
https://twitter.com/lballabio>
------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead.
Download for free and get started troubleshooting in minutes.
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&iu=/4140/ostg.clktrk_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users