|
From: philippe h. <pha...@ma...> - 2024-07-16 01:06:34
|
<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto">By the way how do you handle hard to borrow stock? Is put versus call nor using the same (secured) funding curve or does put call parity no longer hold?<br id="lineBreakAtBeginningOfSignature"><div dir="ltr">Regards<div><br></div><div>Philippe Hatstadt</div><div>+1-203-252-0408</div><div><br></div></div><div dir="ltr"><br><blockquote type="cite">On Jul 15, 2024, at 7:47 PM, James Mac Hale <jam...@qu...> wrote:<br><br></blockquote></div><blockquote type="cite"><div dir="ltr"><div dir="auto">ORE has a class for stripping a forward curve given put and call option prices here <a href="https://github.com/OpenSourceRisk/Engine/blob/master/QuantExt/qle/termstructures/equityforwardcurvestripper.hpp">https://github.com/OpenSourceRisk/Engine/blob/master/QuantExt/qle/termstructures/equityforwardcurvestripper.hpp</a><div dir="auto"><br></div><div dir="auto">That's half the battle. It works well for OPRA SPX data but you need to remove some maturities with only a handful of strikes.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jul 15, 2024, 10:19 PM philippe hatstadt via QuantLib-users <<a href="mailto:qua...@li...">qua...@li...</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">That would be nice.<br> I just built a prototype that uses SPX option quotes, and attempts to derive RidkNeutralForward/Strike for each option, carefully eliminating all calls where such ratio is >= 1 and puts where it is <1.<br> I then compute a BS implied volatility for each option and use such data to build a helpers list, from which I calibrate Heston parameters via ql.LevenbergMarquart. If I then compute the calibration errors, what I observe is that for each helper, the value helper.marketValue() is nowhere near the market values I had used to compute the BS implied volatilities. Such respective values differ by anywhere from 15% to 65% relative option premium.<br> I suppose I need to post some code if I want someone to help? But curious of the steps I took are ok?<br> Regards<br> <br> Philippe Hatstadt<br> +1-203-252-0408<br> <br> <br> > On Jul 15, 2024, at 2:35 PM, Peter Caspers <<a href="mailto:pca...@gm..." target="_blank" rel="noreferrer">pca...@gm...</a>> wrote:<br> > <br> > Maybe we should add a PriceCalibrationHelper that inherits from<br> > CalibrationHelper and a HestonPriceCalibrationHelper from<br> > PriceCalibrationHelper. Both of them operate directly in premium space<br> > rather than vol space.<br> > <br> >> On Fri, 12 Jul 2024 at 22:15, Philippe Hatstadt <<a href="mailto:pha...@ma..." target="_blank" rel="noreferrer">pha...@ma...</a>> wrote:<br> >> <br> >> So if what I have are option quotes, I need to:<br> >> 1. compute the risk-neutral forward for each expiry, replicating exactly what the Heston engine does? is there a way to do that using the engine? If not, what's the best way?<br> >> 2. Use a BSM model, again making sure that it computes the same exact risk-neutral forward, compute the BSM implied volatility, correctly using either a call or a put depending on OTM forward.<br> >> 3. Pass the vols and strikes to the HestonHelpers?<br> >> <br> >> For #1 and #2, I assume that passing the same exact dividend and risk-free rate handles to the respective BSM and Heston engines would guarantee matching risk-neutral forwards, but is there another approach altogether given than what I have are call and put prices?<br> >> <br> >> Philippe Hatstadt 203-252-0408 <a href="https://www.linkedin.com/in/philippe-hatstadt/" rel="noreferrer noreferrer" target="_blank">https://www.linkedin.com/in/philippe-hatstadt/</a><br> >> <br> >> On Jul 12, 2024, at 4:06 PM, Peter Caspers <<a href="mailto:pca...@gm..." target="_blank" rel="noreferrer">pca...@gm...</a>> wrote:<br> >> <br> >> <br> >> forward I believe<br> >> <br> >> <br> >> ------- Weitergeleitete Nachricht ------<br> >> Von: philippe hatstadt <<a href="mailto:pha...@ma..." target="_blank" rel="noreferrer">pha...@ma...</a>><br> >> Datum: Fr. 12. Juli 2024 um 20:37<br> >> Betreff: Re: [Quantlib-users] Heston Calibration<br> >> An: Peter Caspers <<a href="mailto:pca...@gm..." target="_blank" rel="noreferrer">pca...@gm...</a>><br> >> Cc: <<a href="mailto:qua...@li..." target="_blank" rel="noreferrer">qua...@li...</a>><br> >> <br> >> <br> >> Out of the money spot or forward?<br> >> Regards<br> >> <br> >> Philippe Hatstadt<br> >> +1-203-252-0408<br> >> <br> >> <br> >>>> On Jul 12, 2024, at 2:10 PM, Peter Caspers <<a href="mailto:pca...@gm..." target="_blank" rel="noreferrer">pca...@gm...</a>> wrote:<br> >>> <br> >>> Yes. It will always build the option type which is out-of-the-money.<br> >>> Best, Peter<br> >>> <br> >>>> On Fri, 12 Jul 2024 at 18:30, Philippe Hatstadt via QuantLib-users<br> >>>> <<a href="mailto:qua...@li..." target="_blank" rel="noreferrer">qua...@li...</a>> wrote:<br> >>>> <br> >>>> Does the ql.HestonModelHelper only expects a BSM implied volatility as an input? I am asking because there doesn't seem to be any parameter for option type (call or put)?<br> >>>> <br> >>>> Best regards Philippe Hatstadt 203-252-0408 <a href="https://www.linkedin.com/in/philippe-hatstadt/" rel="noreferrer noreferrer" target="_blank">https://www.linkedin.com/in/philippe-hatstadt/</a><br> >>>> <br> >>>> <br> >>>> _______________________________________________<br> >>>> QuantLib-users mailing list<br> >>>> <a href="mailto:Qua...@li..." target="_blank" rel="noreferrer">Qua...@li...</a><br> >>>> <a href="https://lists.sourceforge.net/lists/listinfo/quantlib-users" rel="noreferrer noreferrer" target="_blank">https://lists.sourceforge.net/lists/listinfo/quantlib-users</a><br> >> <br> >> <br> <br> <br> _______________________________________________<br> QuantLib-users mailing list<br> <a href="mailto:Qua...@li..." target="_blank" rel="noreferrer">Qua...@li...</a><br> <a href="https://lists.sourceforge.net/lists/listinfo/quantlib-users" rel="noreferrer noreferrer" target="_blank">https://lists.sourceforge.net/lists/listinfo/quantlib-users</a><br> </blockquote></div> </div></blockquote></body></html> |