You can subscribe to this list here.
| 2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(17) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(23) |
| 2002 |
Jan
(18) |
Feb
(20) |
Mar
(22) |
Apr
(41) |
May
(28) |
Jun
(25) |
Jul
(10) |
Aug
(7) |
Sep
(5) |
Oct
(20) |
Nov
(13) |
Dec
(11) |
| 2003 |
Jan
(28) |
Feb
(5) |
Mar
(6) |
Apr
(5) |
May
(17) |
Jun
(6) |
Jul
(45) |
Aug
(35) |
Sep
(24) |
Oct
(50) |
Nov
(53) |
Dec
(6) |
| 2004 |
Jan
(4) |
Feb
(10) |
Mar
(52) |
Apr
(46) |
May
(8) |
Jun
(25) |
Jul
(12) |
Aug
(6) |
Sep
(8) |
Oct
(8) |
Nov
(9) |
Dec
(7) |
| 2005 |
Jan
(18) |
Feb
(60) |
Mar
(19) |
Apr
(26) |
May
(14) |
Jun
(27) |
Jul
(8) |
Aug
(15) |
Sep
(19) |
Oct
(53) |
Nov
(20) |
Dec
(23) |
| 2006 |
Jan
(16) |
Feb
(27) |
Mar
(33) |
Apr
(51) |
May
(36) |
Jun
(25) |
Jul
(54) |
Aug
(30) |
Sep
(25) |
Oct
(67) |
Nov
(43) |
Dec
(13) |
| 2007 |
Jan
(23) |
Feb
(27) |
Mar
(55) |
Apr
(79) |
May
(60) |
Jun
(66) |
Jul
(46) |
Aug
(30) |
Sep
(90) |
Oct
(49) |
Nov
(85) |
Dec
(74) |
| 2008 |
Jan
(68) |
Feb
(59) |
Mar
(64) |
Apr
(28) |
May
(66) |
Jun
(35) |
Jul
(73) |
Aug
(76) |
Sep
(65) |
Oct
(46) |
Nov
(41) |
Dec
(19) |
| 2009 |
Jan
(46) |
Feb
(90) |
Mar
(51) |
Apr
(104) |
May
(13) |
Jun
(24) |
Jul
(20) |
Aug
(39) |
Sep
(109) |
Oct
(101) |
Nov
(117) |
Dec
(57) |
| 2010 |
Jan
(55) |
Feb
(42) |
Mar
(39) |
Apr
(22) |
May
(33) |
Jun
(41) |
Jul
(25) |
Aug
(52) |
Sep
(75) |
Oct
(60) |
Nov
(62) |
Dec
(52) |
| 2011 |
Jan
(70) |
Feb
(31) |
Mar
(26) |
Apr
(28) |
May
(17) |
Jun
(38) |
Jul
(51) |
Aug
(35) |
Sep
(27) |
Oct
(35) |
Nov
(10) |
Dec
(20) |
| 2012 |
Jan
(21) |
Feb
(29) |
Mar
(13) |
Apr
(37) |
May
(33) |
Jun
(12) |
Jul
(34) |
Aug
(27) |
Sep
(29) |
Oct
(35) |
Nov
(58) |
Dec
(27) |
| 2013 |
Jan
(27) |
Feb
(16) |
Mar
(40) |
Apr
(16) |
May
(34) |
Jun
(37) |
Jul
(6) |
Aug
(3) |
Sep
(4) |
Oct
(49) |
Nov
(13) |
Dec
(12) |
| 2014 |
Jan
(15) |
Feb
(21) |
Mar
(11) |
Apr
(13) |
May
(27) |
Jun
(60) |
Jul
(19) |
Aug
(29) |
Sep
(20) |
Oct
(28) |
Nov
(41) |
Dec
(15) |
| 2015 |
Jan
(33) |
Feb
(29) |
Mar
(26) |
Apr
(17) |
May
(2) |
Jun
(13) |
Jul
(21) |
Aug
(30) |
Sep
(22) |
Oct
(15) |
Nov
(46) |
Dec
(20) |
| 2016 |
Jan
(6) |
Feb
(5) |
Mar
(9) |
Apr
(15) |
May
(9) |
Jun
(4) |
Jul
(3) |
Aug
(4) |
Sep
(39) |
Oct
(8) |
Nov
(5) |
Dec
(8) |
| 2017 |
Jan
(4) |
Feb
(14) |
Mar
(4) |
Apr
(16) |
May
(5) |
Jun
(10) |
Jul
(25) |
Aug
(2) |
Sep
(5) |
Oct
(11) |
Nov
(8) |
Dec
(11) |
| 2018 |
Jan
(7) |
Feb
(4) |
Mar
|
Apr
(1) |
May
(4) |
Jun
(21) |
Jul
(8) |
Aug
(3) |
Sep
(2) |
Oct
(2) |
Nov
(1) |
Dec
|
| 2019 |
Jan
(1) |
Feb
(5) |
Mar
(18) |
Apr
(9) |
May
(5) |
Jun
(21) |
Jul
(25) |
Aug
(25) |
Sep
(4) |
Oct
(2) |
Nov
(2) |
Dec
(5) |
| 2020 |
Jan
|
Feb
|
Mar
(3) |
Apr
|
May
(2) |
Jun
(2) |
Jul
(1) |
Aug
|
Sep
(1) |
Oct
(2) |
Nov
(6) |
Dec
|
| 2021 |
Jan
(1) |
Feb
|
Mar
(2) |
Apr
(1) |
May
(4) |
Jun
|
Jul
(1) |
Aug
|
Sep
(2) |
Oct
(9) |
Nov
(1) |
Dec
(5) |
| 2022 |
Jan
(7) |
Feb
(3) |
Mar
|
Apr
(2) |
May
(5) |
Jun
(3) |
Jul
(3) |
Aug
(3) |
Sep
(3) |
Oct
(14) |
Nov
|
Dec
(1) |
| 2023 |
Jan
(10) |
Feb
|
Mar
|
Apr
(2) |
May
|
Jun
(2) |
Jul
(2) |
Aug
(1) |
Sep
|
Oct
(5) |
Nov
|
Dec
|
| 2024 |
Jan
(8) |
Feb
|
Mar
(2) |
Apr
(1) |
May
|
Jun
|
Jul
(4) |
Aug
(5) |
Sep
|
Oct
(4) |
Nov
(1) |
Dec
(1) |
| 2025 |
Jan
(3) |
Feb
(2) |
Mar
(2) |
Apr
(1) |
May
(2) |
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2026 |
Jan
(1) |
Feb
(12) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Dirk E. <ed...@de...> - 2026-02-27 03:26:18
|
On 16 February 2026 at 17:12, Dirk Eddelbuettel wrote: | FWIW I cannot make heads or tails of that example. I came up with implied vol | below either 116 or 141%. I had promised myself to revisit this, and I finally did. It turns out I had a parameter entry error. Once I adjust that I am right where Luigi had his results, i.e. difference decimals past 115% depending on daycounter convention used. This also made me realize that instead of maturity as the usual 'fractional part of a year' I should alternatively pass the expiry date down. Which I have now done, as well as the dayCounter convention. With that the R results match the Python results as they should as both go to the same C++ library. Dirk -- dirk.eddelbuettel.com | @eddelbuettel | ed...@de... |
|
From: Al C. <aca...@al...> - 2026-02-17 17:02:26
|
Hi Dirk,
This is our code:
def calc_option_implied_vol(self, instrument_model: BaseModel, parameter_model: BaseModel = None,
market_data_model: BaseModel = None):
equity_option_instrument = self.get_equity_option_instrument(instrument_model)
evaluationDate = Utils.extract_input_model("evaluationDate", parameter_model)
optionPrice = Utils.extract_input_model("optionPrice", parameter_model)
spotPrice = Utils.extract_input_model("spotPrice", parameter_model)
dayCounter = Utils.extract_input_model("dayCounter", parameter_model)
calendar = Utils.extract_input_model("calendar", market_data_model)
irCurveTenors = Utils.extract_input_model("irCurveTenors", market_data_model)
irCurveZeroRates = Utils.extract_input_model("irCurveZeroRates", market_data_model)
dividendYield = Utils.extract_input_model("dividendYield", market_data_model)
exerciseType = Utils.extract_input_model("exerciseType", instrument_model)
dummyVolatility = 0.2
volQuote = ql.SimpleQuote(dummyVolatility)
dividendCurve = self._buildDividendCurve(evaluationDate, dividendYield, dayCounter)
irCurve = self._buildInterestCurve(evaluationDate, calendar, dayCounter, irCurveTenors, irCurveZeroRates)
volTS = self._buildVol(evaluationDate, calendar, dayCounter, volQuote)
bsmProcess = ql.BlackScholesMertonProcess(
ql.QuoteHandle(ql.SimpleQuote(spotPrice)),
ql.YieldTermStructureHandle(dividendCurve),
ql.YieldTermStructureHandle(irCurve),
ql.BlackVolTermStructureHandle(volTS))
ql.Settings.instance().evaluationDate = evaluationDate
if exerciseType == "European":
equity_option_instrument.setPricingEngine(ql.AnalyticEuropeanEngine(bsmProcess))
elif exerciseType == "American":
if self.americanEngine == "FdBlackScholesVanillaEngine":
aEngine = ql.FdBlackScholesVanillaEngine(bsmProcess, 100, 100)
elif self.americanEngine == "BinomialVanillaEngine":
aEngine = ql.BinomialVanillaEngine(bsmProcess, "crr", 400)
else:
raise MMException(f"Unsupported americanEngine {self.americanEngine}")
equity_option_instrument.setPricingEngine(aEngine)
else:
raise MMException(f"Unsupported exercise type {exerciseType}")
impliedVol = equity_option_instrument.impliedVolatility(optionPrice, bsmProcess, 1e-6, 1000, 0.001, 4.0)
return impliedVol
My Best
-Al
Cell # 917-603-8000
www.AlphaAnalitica.com
This e-mail is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent responsible for delivering the message to the intended recipient, is prohibited. If you have received this e-mail in error, please notify us immediately (646-205-3213 or in...@Al...) and destroy the original message and all copies.
-----Original Message-----
From: Dirk Eddelbuettel <ed...@de...>
Sent: Monday, February 16, 2026 6:13 PM
To: Dirk Eddelbuettel <ed...@de...>
Cc: Al Cabrini <aca...@al...>; qua...@li...
Subject: RE: [Quantlib-dev] FW: Welcome to the "QuantLib-dev" mailing list
On 16 February 2026 at 16:11, Dirk Eddelbuettel wrote:
|
| On 16 February 2026 at 22:02, Al Cabrini wrote:
| | Thank you Dirk,
| |
| | I added comment below
| |
| | Ticker = BE 03/06/26 C155 Equity
| | OPT_PUT_CALL = Call
| | OPT_STRIKE_PX = 155
| | OPT_EXER_TYP = American
| | OPT_EXERCISE_DT = Mar-20-2026
| | OPT_UNDL_PX = 138.75
| | Option Price MID = 9.475
| | evaluation date = Feb-13-2026
| |
| | Here is the Bloomberg value for implied Vol is 116.124 but my
| | Quantlib calculatin is 141.3
|
| Show as your call to quantlib, please. The issue will likely be that
| you transcribed parameters the wrong way. Sometimes it is
| daysdifference/365 instead of over 252 or vice versa. It all depends.
| And it is good practice to calibrate so I would start with spot =
| strike = 100, t_to_mat = 1 year, vol = 25%, r = 0.04 etc and see if I can start aligning call or put prices.
|
| This library is well known, and had a million eyes on it. It is not
| likely that the code is off. That leaves ... the invocation.
|
| So show us what you did.
FWIW I cannot make heads or tails of that example. I came up with implied vol below either 116 or 141%.
To reset, consider a posted example for a European call option posted here:
https://en.wikipedia.org/wiki/Implied_volatility
This recomputes for me (using RQuantLib)
> EuropeanOptionImpliedVolatility(type="call", value=2, underlying=51.25, strike=50, dividendYield=0.00, riskFreeRate=0.05, maturity=32/365, volatility=0.4)
[1] 0.186925
attr(,"class")
[1] "EuropeanOptionImpliedVolatility" "ImpliedVolatility"
>
matching the stipulated 18.7% on the wikipedia page.
Dirk
--
dirk.eddelbuettel.com | @eddelbuettel | ed...@de...
|
|
From: Al C. <aca...@al...> - 2026-02-17 13:59:51
|
They all expire at 4pm new York time My Best -Al Cell # 917-603-8000 www.AlphaAnalitica.com<http://www.conformity360.com/> This e-mail is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent responsible for delivering the message to the intended recipient, is prohibited. If you have received this e-mail in error, please notify us immediately (646-205-3213 or in...@Al...<mailto:in...@Al...>) and destroy the original message and all copies. From: Luigi Ballabio <lui...@gm...> Sent: Tuesday, February 17, 2026 8:48 AM To: Al Cabrini <aca...@al...> Cc: Dirk Eddelbuettel <ed...@de...>; qua...@li... Subject: Re: [Quantlib-dev] FW: Welcome to the "QuantLib-dev" mailing list It looks plausible. Do you have the time information as well? (e.g. the expiry at 16:00) On Tue, Feb 17, 2026 at 12:41 PM Al Cabrini <aca...@al...<mailto:aca...@al...>> wrote: Hi Luigi, I got this (see attached) from someone on the net. Is this correct? My Best -Al Cell # 917-603-8000 www.AlphaAnalitica.com<http://www.conformity360.com/> This e-mail is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent responsible for delivering the message to the intended recipient, is prohibited. If you have received this e-mail in error, please notify us immediately (646-205-3213 or in...@Al...<mailto:in...@Al...>) and destroy the original message and all copies. From: Luigi Ballabio <lui...@gm...<mailto:lui...@gm...>> Sent: Tuesday, February 17, 2026 4:01 AM To: Dirk Eddelbuettel <ed...@de...<mailto:ed...@de...>> Cc: qua...@li...<mailto:qua...@li...> Subject: Re: [Quantlib-dev] FW: Welcome to the "QuantLib-dev" mailing list Hi, here is how I would calculate it: import QuantLib as ql today = ql.Date(13, 2, 2026) ql.Settings.instance().evaluationDate = today option = ql.VanillaOption( ql.PlainVanillaPayoff(ql.Option.Call, 155), ql.AmericanExercise(today, ql.Date(6,3,2026)), ) calendar = ql.UnitedStates(ql.UnitedStates.GovernmentBond) day_counter = ql.Actual365Fixed() u = ql.QuoteHandle(ql.SimpleQuote(138.75)) q = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0, day_counter)) r = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0366, day_counter)) vol_s = ql.BlackVolTermStructureHandle(ql.BlackConstantVol(today, calendar, 1.112938, day_counter)) p = ql.GeneralizedBlackScholesProcess(u, q, r, vol_s) print(100 * option.impliedVolatility(9.475, p)) This prints 115.899, not quite the same as Bloomberg's 116.124 but a lot closer than your 141. As Dirk says, you might have some problem in the way you're calling the library. (Also, changing day_counter to Act/360 prints 115.092, and changing it to Business252(calendar) prints 117.971, so it's worth trying to figure out from the BBG docs—if you have any—which one is correct.) Hope this helps, Luigi On Tue, Feb 17, 2026 at 1:05 AM Dirk Eddelbuettel <ed...@de...<mailto:ed...@de...>> wrote: On 16 February 2026 at 16:11, Dirk Eddelbuettel wrote: | | On 16 February 2026 at 22:02, Al Cabrini wrote: | | Thank you Dirk, | | | | I added comment below | | | | Ticker = BE 03/06/26 C155 Equity | | OPT_PUT_CALL = Call | | OPT_STRIKE_PX = 155 | | OPT_EXER_TYP = American | | OPT_EXERCISE_DT = Mar-20-2026 | | OPT_UNDL_PX = 138.75 | | Option Price MID = 9.475 | | evaluation date = Feb-13-2026 | | | | Here is the Bloomberg value for implied Vol is 116.124 but my Quantlib calculatin is 141.3 | | Show as your call to quantlib, please. The issue will likely be that you | transcribed parameters the wrong way. Sometimes it is daysdifference/365 | instead of over 252 or vice versa. It all depends. And it is good practice to | calibrate so I would start with spot = strike = 100, t_to_mat = 1 year, vol = | 25%, r = 0.04 etc and see if I can start aligning call or put prices. | | This library is well known, and had a million eyes on it. It is not likely | that the code is off. That leaves ... the invocation. | | So show us what you did. FWIW I cannot make heads or tails of that example. I came up with implied vol below either 116 or 141%. To reset, consider a posted example for a European call option posted here: https://en.wikipedia.org/wiki/Implied_volatility This recomputes for me (using RQuantLib) > EuropeanOptionImpliedVolatility(type="call", value=2, underlying=51.25, strike=50, dividendYield=0.00, riskFreeRate=0.05, maturity=32/365, volatility=0.4) [1] 0.186925 attr(,"class") [1] "EuropeanOptionImpliedVolatility" "ImpliedVolatility" > matching the stipulated 18.7% on the wikipedia page. Dirk -- dirk.eddelbuettel.com<http://dirk.eddelbuettel.com> | @eddelbuettel | ed...@de...<mailto:ed...@de...> _______________________________________________ QuantLib-dev mailing list Qua...@li...<mailto:Qua...@li...> https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
|
From: Luigi B. <lui...@gm...> - 2026-02-17 13:48:45
|
It looks plausible. Do you have the time information as well? (e.g. the expiry at 16:00) On Tue, Feb 17, 2026 at 12:41 PM Al Cabrini <aca...@al...> wrote: > Hi Luigi, > > > > I got this (see attached) from someone on the net. > > > > Is this correct? > > > > > > My Best > > -Al > > Cell # 917-603-8000 > > www.AlphaAnalitica.com <http://www.conformity360.com/> > > > > This e-mail is intended only for the person or entity to which it is > addressed and may contain information that is privileged, confidential or > otherwise protected from disclosure. Dissemination, distribution or copying > of this e-mail or the information herein by anyone other than the intended > recipient, or an employee or agent responsible for delivering the message > to the intended recipient, is prohibited. If you have received this e-mail > in error, please notify us immediately (646-205-3213 or > in...@Al...) and destroy the original message and all copies. > > > > > > *From:* Luigi Ballabio <lui...@gm...> > *Sent:* Tuesday, February 17, 2026 4:01 AM > *To:* Dirk Eddelbuettel <ed...@de...> > *Cc:* qua...@li... > *Subject:* Re: [Quantlib-dev] FW: Welcome to the "QuantLib-dev" mailing > list > > > > Hi, here is how I would calculate it: > > > > import QuantLib as ql > > today = ql.Date(13, 2, 2026) > ql.Settings.instance().evaluationDate = today > > option = ql.VanillaOption( > ql.PlainVanillaPayoff(ql.Option.Call, 155), > ql.AmericanExercise(today, ql.Date(6,3,2026)), > ) > > calendar = ql.UnitedStates(ql.UnitedStates.GovernmentBond) > day_counter = ql.Actual365Fixed() > > u = ql.QuoteHandle(ql.SimpleQuote(138.75)) > q = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0, day_counter)) > r = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0366, day_counter)) > vol_s = ql.BlackVolTermStructureHandle(ql.BlackConstantVol(today, > calendar, 1.112938, day_counter)) > > p = ql.GeneralizedBlackScholesProcess(u, q, r, vol_s) > > print(100 * option.impliedVolatility(9.475, p)) > > > > This prints 115.899, not quite the same as Bloomberg's 116.124 but a lot > closer than your 141. As Dirk says, you might have some problem in the way > you're calling the library. > > > > (Also, changing day_counter to Act/360 prints 115.092, and changing it to > Business252(calendar) prints 117.971, so it's worth trying to figure out > from the BBG docs—if you have any—which one is correct.) > > > > Hope this helps, > > Luigi > > > > > > > > > > On Tue, Feb 17, 2026 at 1:05 AM Dirk Eddelbuettel <ed...@de...> wrote: > > > On 16 February 2026 at 16:11, Dirk Eddelbuettel wrote: > | > | On 16 February 2026 at 22:02, Al Cabrini wrote: > | | Thank you Dirk, > | | > | | I added comment below > | | > | | Ticker = BE 03/06/26 C155 Equity > | | OPT_PUT_CALL = Call > | | OPT_STRIKE_PX = 155 > | | OPT_EXER_TYP = American > | | OPT_EXERCISE_DT = Mar-20-2026 > | | OPT_UNDL_PX = 138.75 > | | Option Price MID = 9.475 > | | evaluation date = Feb-13-2026 > | | > | | Here is the Bloomberg value for implied Vol is 116.124 but my Quantlib > calculatin is 141.3 > | > | Show as your call to quantlib, please. The issue will likely be that you > | transcribed parameters the wrong way. Sometimes it is daysdifference/365 > | instead of over 252 or vice versa. It all depends. And it is good > practice to > | calibrate so I would start with spot = strike = 100, t_to_mat = 1 year, > vol = > | 25%, r = 0.04 etc and see if I can start aligning call or put prices. > | > | This library is well known, and had a million eyes on it. It is not > likely > | that the code is off. That leaves ... the invocation. > | > | So show us what you did. > > FWIW I cannot make heads or tails of that example. I came up with implied > vol > below either 116 or 141%. > > To reset, consider a posted example for a European call option posted here: > https://en.wikipedia.org/wiki/Implied_volatility > > This recomputes for me (using RQuantLib) > > > EuropeanOptionImpliedVolatility(type="call", value=2, > underlying=51.25, strike=50, dividendYield=0.00, riskFreeRate=0.05, > maturity=32/365, volatility=0.4) > [1] 0.186925 > attr(,"class") > [1] "EuropeanOptionImpliedVolatility" "ImpliedVolatility" > > > > matching the stipulated 18.7% on the wikipedia page. > > Dirk > > -- > dirk.eddelbuettel.com | @eddelbuettel | ed...@de... > > > _______________________________________________ > QuantLib-dev mailing list > Qua...@li... > https://lists.sourceforge.net/lists/listinfo/quantlib-dev > > |
|
From: Al C. <aca...@al...> - 2026-02-17 11:41:51
|
Hi Luigi, I got this (see attached) from someone on the net. Is this correct? My Best -Al Cell # 917-603-8000 www.AlphaAnalitica.com<http://www.conformity360.com/> This e-mail is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent responsible for delivering the message to the intended recipient, is prohibited. If you have received this e-mail in error, please notify us immediately (646-205-3213 or in...@Al...<mailto:in...@Al...>) and destroy the original message and all copies. From: Luigi Ballabio <lui...@gm...> Sent: Tuesday, February 17, 2026 4:01 AM To: Dirk Eddelbuettel <ed...@de...> Cc: qua...@li... Subject: Re: [Quantlib-dev] FW: Welcome to the "QuantLib-dev" mailing list Hi, here is how I would calculate it: import QuantLib as ql today = ql.Date(13, 2, 2026) ql.Settings.instance().evaluationDate = today option = ql.VanillaOption( ql.PlainVanillaPayoff(ql.Option.Call, 155), ql.AmericanExercise(today, ql.Date(6,3,2026)), ) calendar = ql.UnitedStates(ql.UnitedStates.GovernmentBond) day_counter = ql.Actual365Fixed() u = ql.QuoteHandle(ql.SimpleQuote(138.75)) q = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0, day_counter)) r = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0366, day_counter)) vol_s = ql.BlackVolTermStructureHandle(ql.BlackConstantVol(today, calendar, 1.112938, day_counter)) p = ql.GeneralizedBlackScholesProcess(u, q, r, vol_s) print(100 * option.impliedVolatility(9.475, p)) This prints 115.899, not quite the same as Bloomberg's 116.124 but a lot closer than your 141. As Dirk says, you might have some problem in the way you're calling the library. (Also, changing day_counter to Act/360 prints 115.092, and changing it to Business252(calendar) prints 117.971, so it's worth trying to figure out from the BBG docs—if you have any—which one is correct.) Hope this helps, Luigi On Tue, Feb 17, 2026 at 1:05 AM Dirk Eddelbuettel <ed...@de...<mailto:ed...@de...>> wrote: On 16 February 2026 at 16:11, Dirk Eddelbuettel wrote: | | On 16 February 2026 at 22:02, Al Cabrini wrote: | | Thank you Dirk, | | | | I added comment below | | | | Ticker = BE 03/06/26 C155 Equity | | OPT_PUT_CALL = Call | | OPT_STRIKE_PX = 155 | | OPT_EXER_TYP = American | | OPT_EXERCISE_DT = Mar-20-2026 | | OPT_UNDL_PX = 138.75 | | Option Price MID = 9.475 | | evaluation date = Feb-13-2026 | | | | Here is the Bloomberg value for implied Vol is 116.124 but my Quantlib calculatin is 141.3 | | Show as your call to quantlib, please. The issue will likely be that you | transcribed parameters the wrong way. Sometimes it is daysdifference/365 | instead of over 252 or vice versa. It all depends. And it is good practice to | calibrate so I would start with spot = strike = 100, t_to_mat = 1 year, vol = | 25%, r = 0.04 etc and see if I can start aligning call or put prices. | | This library is well known, and had a million eyes on it. It is not likely | that the code is off. That leaves ... the invocation. | | So show us what you did. FWIW I cannot make heads or tails of that example. I came up with implied vol below either 116 or 141%. To reset, consider a posted example for a European call option posted here: https://en.wikipedia.org/wiki/Implied_volatility This recomputes for me (using RQuantLib) > EuropeanOptionImpliedVolatility(type="call", value=2, underlying=51.25, strike=50, dividendYield=0.00, riskFreeRate=0.05, maturity=32/365, volatility=0.4) [1] 0.186925 attr(,"class") [1] "EuropeanOptionImpliedVolatility" "ImpliedVolatility" > matching the stipulated 18.7% on the wikipedia page. Dirk -- dirk.eddelbuettel.com<http://dirk.eddelbuettel.com> | @eddelbuettel | ed...@de...<mailto:ed...@de...> _______________________________________________ QuantLib-dev mailing list Qua...@li...<mailto:Qua...@li...> https://lists.sourceforge.net/lists/listinfo/quantlib-dev |
|
From: Luigi B. <lui...@gm...> - 2026-02-17 09:00:54
|
Hi, here is how I would calculate it:
import QuantLib as ql
today = ql.Date(13, 2, 2026)
ql.Settings.instance().evaluationDate = today
option = ql.VanillaOption(
ql.PlainVanillaPayoff(ql.Option.Call, 155),
ql.AmericanExercise(today, ql.Date(6,3,2026)),
)
calendar = ql.UnitedStates(ql.UnitedStates.GovernmentBond)
day_counter = ql.Actual365Fixed()
u = ql.QuoteHandle(ql.SimpleQuote(138.75))
q = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0, day_counter))
r = ql.YieldTermStructureHandle(ql.FlatForward(today, 0.0366, day_counter))
vol_s = ql.BlackVolTermStructureHandle(ql.BlackConstantVol(today, calendar,
1.112938, day_counter))
p = ql.GeneralizedBlackScholesProcess(u, q, r, vol_s)
print(100 * option.impliedVolatility(9.475, p))
This prints 115.899, not quite the same as Bloomberg's 116.124 but a lot
closer than your 141. As Dirk says, you might have some problem in the way
you're calling the library.
(Also, changing day_counter to Act/360 prints 115.092, and changing it to
Business252(calendar) prints 117.971, so it's worth trying to figure out
from the BBG docs—if you have any—which one is correct.)
Hope this helps,
Luigi
On Tue, Feb 17, 2026 at 1:05 AM Dirk Eddelbuettel <ed...@de...> wrote:
>
> On 16 February 2026 at 16:11, Dirk Eddelbuettel wrote:
> |
> | On 16 February 2026 at 22:02, Al Cabrini wrote:
> | | Thank you Dirk,
> | |
> | | I added comment below
> | |
> | | Ticker = BE 03/06/26 C155 Equity
> | | OPT_PUT_CALL = Call
> | | OPT_STRIKE_PX = 155
> | | OPT_EXER_TYP = American
> | | OPT_EXERCISE_DT = Mar-20-2026
> | | OPT_UNDL_PX = 138.75
> | | Option Price MID = 9.475
> | | evaluation date = Feb-13-2026
> | |
> | | Here is the Bloomberg value for implied Vol is 116.124 but my Quantlib
> calculatin is 141.3
> |
> | Show as your call to quantlib, please. The issue will likely be that you
> | transcribed parameters the wrong way. Sometimes it is daysdifference/365
> | instead of over 252 or vice versa. It all depends. And it is good
> practice to
> | calibrate so I would start with spot = strike = 100, t_to_mat = 1 year,
> vol =
> | 25%, r = 0.04 etc and see if I can start aligning call or put prices.
> |
> | This library is well known, and had a million eyes on it. It is not
> likely
> | that the code is off. That leaves ... the invocation.
> |
> | So show us what you did.
>
> FWIW I cannot make heads or tails of that example. I came up with implied
> vol
> below either 116 or 141%.
>
> To reset, consider a posted example for a European call option posted here:
> https://en.wikipedia.org/wiki/Implied_volatility
>
> This recomputes for me (using RQuantLib)
>
> > EuropeanOptionImpliedVolatility(type="call", value=2,
> underlying=51.25, strike=50, dividendYield=0.00, riskFreeRate=0.05,
> maturity=32/365, volatility=0.4)
> [1] 0.186925
> attr(,"class")
> [1] "EuropeanOptionImpliedVolatility" "ImpliedVolatility"
> >
>
> matching the stipulated 18.7% on the wikipedia page.
>
> Dirk
>
> --
> dirk.eddelbuettel.com | @eddelbuettel | ed...@de...
>
>
> _______________________________________________
> QuantLib-dev mailing list
> Qua...@li...
> https://lists.sourceforge.net/lists/listinfo/quantlib-dev
>
|
|
From: Dirk E. <ed...@de...> - 2026-02-17 00:04:36
|
On 16 February 2026 at 16:11, Dirk Eddelbuettel wrote: | | On 16 February 2026 at 22:02, Al Cabrini wrote: | | Thank you Dirk, | | | | I added comment below | | | | Ticker = BE 03/06/26 C155 Equity | | OPT_PUT_CALL = Call | | OPT_STRIKE_PX = 155 | | OPT_EXER_TYP = American | | OPT_EXERCISE_DT = Mar-20-2026 | | OPT_UNDL_PX = 138.75 | | Option Price MID = 9.475 | | evaluation date = Feb-13-2026 | | | | Here is the Bloomberg value for implied Vol is 116.124 but my Quantlib calculatin is 141.3 | | Show as your call to quantlib, please. The issue will likely be that you | transcribed parameters the wrong way. Sometimes it is daysdifference/365 | instead of over 252 or vice versa. It all depends. And it is good practice to | calibrate so I would start with spot = strike = 100, t_to_mat = 1 year, vol = | 25%, r = 0.04 etc and see if I can start aligning call or put prices. | | This library is well known, and had a million eyes on it. It is not likely | that the code is off. That leaves ... the invocation. | | So show us what you did. FWIW I cannot make heads or tails of that example. I came up with implied vol below either 116 or 141%. To reset, consider a posted example for a European call option posted here: https://en.wikipedia.org/wiki/Implied_volatility This recomputes for me (using RQuantLib) > EuropeanOptionImpliedVolatility(type="call", value=2, underlying=51.25, strike=50, dividendYield=0.00, riskFreeRate=0.05, maturity=32/365, volatility=0.4) [1] 0.186925 attr(,"class") [1] "EuropeanOptionImpliedVolatility" "ImpliedVolatility" > matching the stipulated 18.7% on the wikipedia page. Dirk -- dirk.eddelbuettel.com | @eddelbuettel | ed...@de... |
|
From: Dirk E. <ed...@de...> - 2026-02-16 22:12:10
|
On 16 February 2026 at 22:02, Al Cabrini wrote: | Thank you Dirk, | | I added comment below | | Ticker = BE 03/06/26 C155 Equity | OPT_PUT_CALL = Call | OPT_STRIKE_PX = 155 | OPT_EXER_TYP = American | OPT_EXERCISE_DT = Mar-20-2026 | OPT_UNDL_PX = 138.75 | Option Price MID = 9.475 | evaluation date = Feb-13-2026 | | Here is the Bloomberg value for implied Vol is 116.124 but my Quantlib calculatin is 141.3 Show as your call to quantlib, please. The issue will likely be that you transcribed parameters the wrong way. Sometimes it is daysdifference/365 instead of over 252 or vice versa. It all depends. And it is good practice to calibrate so I would start with spot = strike = 100, t_to_mat = 1 year, vol = 25%, r = 0.04 etc and see if I can start aligning call or put prices. This library is well known, and had a million eyes on it. It is not likely that the code is off. That leaves ... the invocation. So show us what you did. Dirk -- dirk.eddelbuettel.com | @eddelbuettel | ed...@de... |
|
From: Al C. <aca...@al...> - 2026-02-16 22:02:22
|
Thank you Dirk, I added comment below Ticker = BE 03/06/26 C155 Equity OPT_PUT_CALL = Call OPT_STRIKE_PX = 155 OPT_EXER_TYP = American OPT_EXERCISE_DT = Mar-20-2026 OPT_UNDL_PX = 138.75 Option Price MID = 9.475 evaluation date = Feb-13-2026 Here is the Bloomberg value for implied Vol is 116.124 but my Quantlib calculatin is 141.3 My Best -Al Cell # 917-603-8000 www.AlphaAnalitica.com This e-mail is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent responsible for delivering the message to the intended recipient, is prohibited. If you have received this e-mail in error, please notify us immediately (646-205-3213 or in...@Al...) and destroy the original message and all copies. -----Original Message----- From: Dirk Eddelbuettel <ed...@de...> Sent: Monday, February 16, 2026 4:27 PM To: Al Cabrini <aca...@al...> Cc: qua...@li... Subject: Re: [Quantlib-dev] FW: Welcome to the "QuantLib-dev" mailing list On 16 February 2026 at 19:40, Al Cabrini via QuantLib-dev wrote: | I am using QuantLib and a few my calculations using QuantLib doesn't match with what Bloomberg has. | For example, Delta or implied Vol not matching | | Where can I post my questions? It would appear you already cross-posted on Quant StatExchange it seems but in neither post did you provide a _minimally complete verifiable example_. Please do so. Post spot, strike, rate, yield, time to expiry etc to allow us to reproduce and then give you comments. Otherwise you can also take an existing QuantLib example (from the docs, or the unit tests) and see about valuating it at a Bbg terminal (if you have access to one). Dirk -- dirk.eddelbuettel.com | @eddelbuettel | ed...@de... |
|
From: Dirk E. <ed...@de...> - 2026-02-16 22:00:41
|
On 16 February 2026 at 19:40, Al Cabrini via QuantLib-dev wrote: | I am using QuantLib and a few my calculations using QuantLib doesn't match with what Bloomberg has. | For example, Delta or implied Vol not matching | | Where can I post my questions? It would appear you already cross-posted on Quant StatExchange it seems but in neither post did you provide a _minimally complete verifiable example_. Please do so. Post spot, strike, rate, yield, time to expiry etc to allow us to reproduce and then give you comments. Otherwise you can also take an existing QuantLib example (from the docs, or the unit tests) and see about valuating it at a Bbg terminal (if you have access to one). Dirk -- dirk.eddelbuettel.com | @eddelbuettel | ed...@de... |
|
From: Luigi B. <lui...@gm...> - 2026-02-16 21:36:44
|
Hello Al — either here or quantlib-users are ok. quantlib-users might have a bit more people on it. Luigi On Mon, Feb 16, 2026 at 8:59 PM Al Cabrini via QuantLib-dev < qua...@li...> wrote: > Hi, > > I am using QuantLib and a few my calculations using QuantLib doesn't match > with what Bloomberg has. > For example, Delta or implied Vol not matching > > Where can I post my questions? > > > My Best > -Al > Cell # 917-603-8000 > www.AlphaAnalitica.com > > This e-mail is intended only for the person or entity to which it is > addressed and may contain information that is privileged, confidential or > otherwise protected from disclosure. Dissemination, distribution or copying > of this e-mail or the information herein by anyone other than the intended > recipient, or an employee or agent responsible for delivering the message > to the intended recipient, is prohibited. If you have received this e-mail > in error, please notify us immediately (646-205-3213 or > in...@Al...) and destroy the original message and all copies. > > > -----Original Message----- > From: qua...@li... < > qua...@li...> > Sent: Monday, February 16, 2026 2:38 PM > To: Al Cabrini <aca...@al...> > Subject: Welcome to the "QuantLib-dev" mailing list > > Welcome to the Qua...@li... mailing list! > Mailing list for QuantLib developers. > > It's assumed that if you're a QuantLib developer you're also subscribed to > <a href="http://lists.sourceforge.net/mailman/listinfo/quantlib-users">quantlib-users</a>. > > So far quantlib-dev is a low volume mailing list. > > To post to this list, send your message to: > > qua...@li... > > General information about the mailing list is at: > > https://lists.sourceforge.net/lists/listinfo/quantlib-dev > > If you ever want to unsubscribe or change your options (eg, switch to or > from digest mode, change your password, etc.), visit your subscription page > at: > > > https://lists.sourceforge.net/lists/options/quantlib-dev/acabrini%40alphaanalitica.com > > > You can also make such adjustments via email by sending a message to: > > Qua...@li... > > with the word `help' in the subject or body (don't include the quotes), > and you will get back a message with instructions. > > You must know your password to change your options (including changing the > password, itself) or to unsubscribe without confirmation. It is: > > erowzaik > > Normally, Mailman will remind you of your lists.sourceforge.net mailing > list passwords once every month, although you can disable this if you > prefer. This reminder will also include instructions on how to unsubscribe > or change your account options. There is also a button on your options > page that will email your current password to you. > > > _______________________________________________ > QuantLib-dev mailing list > Qua...@li... > https://lists.sourceforge.net/lists/listinfo/quantlib-dev > |
|
From: Al C. <aca...@al...> - 2026-02-16 19:53:46
|
Hi, I am using QuantLib and a few my calculations using QuantLib doesn't match with what Bloomberg has. For example, Delta or implied Vol not matching Where can I post my questions? My Best -Al Cell # 917-603-8000 www.AlphaAnalitica.com This e-mail is intended only for the person or entity to which it is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Dissemination, distribution or copying of this e-mail or the information herein by anyone other than the intended recipient, or an employee or agent responsible for delivering the message to the intended recipient, is prohibited. If you have received this e-mail in error, please notify us immediately (646-205-3213 or in...@Al...) and destroy the original message and all copies. -----Original Message----- From: qua...@li... <qua...@li...> Sent: Monday, February 16, 2026 2:38 PM To: Al Cabrini <aca...@al...> Subject: Welcome to the "QuantLib-dev" mailing list Welcome to the Qua...@li... mailing list! Mailing list for QuantLib developers. It's assumed that if you're a QuantLib developer you're also subscribed to <a href="http://lists.sourceforge.net/mailman/listinfo/quantlib-users">quantlib-users</a>. So far quantlib-dev is a low volume mailing list. To post to this list, send your message to: qua...@li... General information about the mailing list is at: https://lists.sourceforge.net/lists/listinfo/quantlib-dev If you ever want to unsubscribe or change your options (eg, switch to or from digest mode, change your password, etc.), visit your subscription page at: https://lists.sourceforge.net/lists/options/quantlib-dev/acabrini%40alphaanalitica.com You can also make such adjustments via email by sending a message to: Qua...@li... with the word `help' in the subject or body (don't include the quotes), and you will get back a message with instructions. You must know your password to change your options (including changing the password, itself) or to unsubscribe without confirmation. It is: erowzaik Normally, Mailman will remind you of your lists.sourceforge.net mailing list passwords once every month, although you can disable this if you prefer. This reminder will also include instructions on how to unsubscribe or change your account options. There is also a button on your options page that will email your current password to you. |
|
From: Luigi B. <lui...@gm...> - 2026-01-13 08:37:19
|
QuantLib 1.41 is available for download at < https://www.quantlib.org/download.shtml>; precompiled binaries are also available from PyPI and NuGet for Python and C# respectively. The list of changes for this release is at < https://github.com/lballabio/QuantLib/releases/tag/v1.41>. If you have any problems with this release, please report them here on the QuantLib mailing list (<qua...@li...>) or open a GitHub issue at <https://github.com/lballabio/quantlib/issues>. |
|
From: Luigi B. <lui...@gm...> - 2025-10-14 07:11:44
|
QuantLib 1.40 is available for download at < https://www.quantlib.org/download.shtml>; precompiled binaries are also available from PyPI and NuGet for Python and C# respectively. The list of changes for this release is at < https://github.com/lballabio/QuantLib/releases/tag/v1.40>. If you have any problems with this release, please report them here on the QuantLib mailing list (<qua...@li...>) or open a GitHub issue at <https://github.com/lballabio/quantlib/issues>. |
|
From: Luigi B. <lui...@gm...> - 2025-07-23 10:25:18
|
QuantLib 1.39 is available for download at < https://www.quantlib.org/download.shtml>; precompiled binaries are also available from PyPI and NuGet for Python and C# respectively. The list of changes for this release is at < https://www.quantlib.org/reference/history.html>. Note that a few recent versions of the Visual C++ 2022 compiler (from 17.14.2 to 17.14.8) had a known bug that, unfortunately, affected QuantLib heavily and made it basically unusable. A fix was released in version 17.14.9; if you’re compiling QuantLib on Windows, make sure you're using at least that version (or, if you can't upgrade, use the Visual C++ 2019 toolset; you can do that from VC++ 2022, as well). Due to this, Python wheels for Windows are not yet available; they will be shortly, when GitHub action runners upgrade to the latest VC++ version. If you have any problems with this release, please report them here on the QuantLib mailing list (<qua...@li...>) or open a GitHub issue at <https://github.com/lballabio/quantlib/issues>. |
|
From: Marcin R. <mry...@gm...> - 2025-05-19 08:00:10
|
Hi Henry,
The FX forward formula seems incorrect. Additionally, you need to calculate
the forwards on the nodes of the MXN curve, and correct for the spot date.
Something like this:
# ====== Step 6: Calculate implied forward rates ======
print("\nImplied Forward USD/MXN Rates:")
fx_spot_date = fx_calendar.advance(today, fixing_days, ql.Days, convention,
end_of_month)
for node, _ in mxn_curve.nodes()[1:]:
# Calculate implied forward rate
usd_discount = usd_curve.discount(node)
usd_discount_spot = usd_curve.discount(fx_spot_date)
mxn_discount = mxn_curve.discount(node)
mxn_discount_spot = mxn_curve.discount(fx_spot_date)
fwd_fx = spot_fx_usdmxn * (usd_discount / mxn_discount) * (
mxn_discount_spot / usd_discount_spot)
points = (fwd_fx - spot_fx_usdmxn) * 10000 # Convert to pips
print(f"{node}: {fwd_fx:.4f} (Points: {points:.1f})")
Hope this helps.
Cheers,
Marcin
On Sat, 17 May 2025 at 14:39, Henry Wu Hu <hen...@gm...> wrote:
> Hello. I am trying to get implied fx forward using the FxRateSwapHelper.
> Some how I am not able to get the same fx forward points when comparing
> with the input.
>
> Am I missing something? All help is appreciated
>
> Thanks in advanced.
>
>
> import QuantLib as ql
> import datetime as dt
> import numpy as np
> import pandas as pd
>
> # Set evaluation date
> today = ql.Date(16, 5, 2025) # May 16, 2025
> ql.Settings.instance().evaluationDate = today
>
> # ====== Step 1: Define market data ======
> # USD yield curve data (assuming we already have this)
> usd_rate_dates = [
> today + ql.Period("1D"),
> today + ql.Period("1W"),
> today + ql.Period("1M"),
> today + ql.Period("3M"),
> today + ql.Period("6M"),
> today + ql.Period("1Y"),
> today + ql.Period("2Y"),
> today + ql.Period("5Y")
> ]
>
> usd_rates = [0.0520, 0.0525, 0.0530, 0.0535, 0.0540, 0.0550, 0.0560,
> 0.0570] # Sample rates
>
> # FX Spot USDMXN rate
> spot_fx_usdmxn = 17.8500 # USD/MXN spot rate
>
> # FX Swap points for different tenors (market quotes in pips)
> fx_swap_tenors = [ql.Period("1M"), ql.Period("3M"), ql.Period("6M"),
> ql.Period("1Y")]
> fx_swap_points = [125, 375, 825, 1750] # Sample swap points in pips
>
> # ====== Step 2: Set up USD curve (base/collateral currency) ======
> usd_day_count = ql.Actual360()
> usd_calendar = ql.UnitedStates(ql.UnitedStates.GovernmentBond)
> usd_interpolation = ql.Linear()
> usd_compounding = ql.Compounded
> usd_compounding_freq = ql.Semiannual
>
> # Create USD deposit rate helpers
> usd_rate_helpers = []
> for rate, maturity in zip(usd_rates, usd_rate_dates):
> if maturity <= today + ql.Period("1Y"): # For maturities up to 1Y
> days_to_maturity = (maturity - today)
> usd_rate_helpers.append(
> ql.DepositRateHelper(
> ql.QuoteHandle(ql.SimpleQuote(rate)),
> ql.Period(days_to_maturity, ql.Days),
> 2, # fixing days
> usd_calendar,
> ql.ModifiedFollowing,
> False,
> usd_day_count
> )
> )
> else: # For longer maturities, assume we're using swap rates
> tenor_length = (maturity - today) / 365 # Approximate in years
> usd_rate_helpers.append(
> ql.SwapRateHelper(
> ql.QuoteHandle(ql.SimpleQuote(rate)),
> ql.Period(int(tenor_length), ql.Years),
> usd_calendar,
> ql.Semiannual,
> ql.ModifiedFollowing,
> usd_day_count,
> ql.Euribor6M() # Example index, in reality would use
> appropriate USD index
> )
> )
>
> # Build USD curve
> usd_curve = ql.PiecewiseLinearZero(
> today, usd_rate_helpers, usd_day_count
> )
> usd_curve_handle = ql.YieldTermStructureHandle(usd_curve)
>
> # ====== Step 3: Set up FX swap rate helpers for MXN curve ======
> mxn_calendar = ql.Mexico()
> # In FX markets, typically both calendars are considered
> fx_calendar = ql.JointCalendar(usd_calendar, mxn_calendar)
> fixing_days = 2 # Standard for FX markets
> convention = ql.Following
> end_of_month = False
> # In USD/MXN, USD is the base currency, and if using USD as collateral:
> is_fx_base_currency_collateral_currency = True
>
> # Create FX swap rate helpers
> fx_swap_helpers = []
> for tenor, points in zip(fx_swap_tenors, fx_swap_points):
> # Convert swap points from pips to decimal
> swap_point_decimal = points / 10000.0
>
> fx_swap_helpers.append(
> ql.FxSwapRateHelper(
> ql.QuoteHandle(ql.SimpleQuote(swap_point_decimal)),
> ql.QuoteHandle(ql.SimpleQuote(spot_fx_usdmxn)),
> tenor,
> fixing_days,
> fx_calendar,
> convention,
> end_of_month,
> is_fx_base_currency_collateral_currency,
> usd_curve_handle
> )
> )
>
> # ====== Step 4: Build MXN curve ======
> mxn_day_count = ql.Actual360()
> mxn_curve = ql.PiecewiseLinearZero(
> today, fx_swap_helpers, mxn_day_count
> )
>
> # ====== Step 5: Analyze the results ======
> print(f"Evaluation date: {today.ISO()}")
> print(f"USD/MXN Spot Rate: {spot_fx_usdmxn}")
> print("\nUSD Zero Rates:")
> for date, rate in zip(usd_rate_dates, usd_rates):
> days = (date - today)
> print(f"{days} days: {rate*100:.4f}%")
>
> print("\nImplied MXN Zero Rates:")
> for tenor in fx_swap_tenors:
> date = today + tenor
> mxn_zero_rate = mxn_curve.zeroRate(
> date, mxn_day_count, ql.Continuous).rate()
> print(f"{tenor}: {mxn_zero_rate*100:.4f}%")
>
> # ====== Step 6: Calculate implied forward rates ======
> print("\nImplied Forward USD/MXN Rates:")
> for tenor in fx_swap_tenors:
> date = today + tenor
> # Calculate implied forward rate
> usd_discount = usd_curve.discount(date)
> mxn_discount = mxn_curve.discount(date)
> fwd_fx = spot_fx_usdmxn * (mxn_discount / usd_discount)
>
> points = (fwd_fx - spot_fx_usdmxn) * 10000 # Convert to pips
> print(f"{tenor}: {fwd_fx:.4f} (Points: {points:.1f})")
>
> Best Regards
> Henry Wu Hu
> _______________________________________________
> QuantLib-users mailing list
> Qua...@li...
> https://lists.sourceforge.net/lists/listinfo/quantlib-users
>
|
|
From: Peter C. <pca...@gm...> - 2025-05-17 07:49:52
|
Dear all, We will be hosting a meeting in London on June 3rd with presentations on the latest in Open-Source Risk Engine and QuantLib - the former is based on the latter, as you might know. There will also be talks on more general quant finance topics. I will attach the full invite below. Would be nice to see you there. Best Peter We’re delighted to invite you to the LSEG Post Trade Solutions (formerly Acadia) *Quant Summit*, taking place at the *LSEG Headquarters* in *London * on *Tuesday 3rd June*. Join us for an exciting day of insights and innovation in quantitative finance, bringing together leading professionals to share their expertise. You are invited to attend our morning Open-Source Risk Engine Technical Masterclass, and/or our afternoon Quant Summit packed with presentations and panels from industry leaders. This free-to-attend event is ideal for Heads of Traded Risk/XVA/Model Validation and Senior Quants supporting FO, risk or model validation and Quant Developers. It’s a fantastic opportunity to exchange ideas and connect with peers from across the industry. Feel free to share with colleagues who may be interested. The link below provides details on the agenda and registration form. https://solutions.lseg.com/Quant_Summit_London_2025 Register now to secure your place. We look forward to welcoming you! |
|
From: Luigi B. <lui...@gm...> - 2025-04-23 08:48:56
|
QuantLib 1.38 is available for download at < https://www.quantlib.org/download.shtml>; precompiled binaries are also available from PyPI and NuGet for Python and C# respectively. The list of changes for this release is at < https://www.quantlib.org/reference/history.html>. If you have any problems with this release, please report them here on the QuantLib mailing list (<qua...@li...>) or open a GitHub issue at <https://github.com/lballabio/quantlib/issues>. |
|
From: Luigi B. <lui...@gm...> - 2025-03-27 14:57:59
|
Hello Leopold,
the multiple-reset feature is relatively recent and it's not available
in SwapRateHelper. There is an open issue about this (
https://github.com/lballabio/QuantLib/issues/2138) so thanks for
posting—I'll point to this thread in that issue as further evidence.
You can follow the issue to check if there's any progress.
Best,
Luigi
On Thu, Mar 27, 2025 at 2:41 PM Leopold Coupet <lc...@ra...> wrote:
> Hello Luigi, regarding IRS that pay less frequently than the index resets.
>
> A real example would be the Canadian swap based on CDOR3M Index. They pay
> semi-annually while resetting quarterly.
> In your article here
> https://www.implementingquantlib.com/2025/02/multiple-resets.html, you
> explain how to price those type of swaps, but my question is how to
> bootstrap the forward zero curve using the ql.SwapRateHelper object. Does
> QuantLib understand that the index resets quarterly, if we define the index
> tenor as ql.Period(“3M”) ? Or is there a way to precise in the swap helper
> object that there is a quarterly reset ?
>
> Thank you very much,
>
> Léopold
> _______________________________________________
> QuantLib-dev mailing list
> Qua...@li...
> https://lists.sourceforge.net/lists/listinfo/quantlib-dev
>
|
|
From: Leopold C. <lc...@ra...> - 2025-03-27 13:40:30
|
Hello Luigi, regarding IRS that pay less frequently than the index resets. A real example would be the Canadian swap based on CDOR3M Index. They pay semi-annually while resetting quarterly. In your article here https://www.implementingquantlib.com/2025/02/multiple-resets.html, you explain how to price those type of swaps, but my question is how to bootstrap the forward zero curve using the ql.SwapRateHelper object. Does QuantLib understand that the index resets quarterly, if we define the index tenor as ql.Period(“3M”) ? Or is there a way to precise in the swap helper object that there is a quarterly reset ? Thank you very much, Léopold |
|
From: Luigi B. <lui...@gm...> - 2025-02-13 16:50:12
|
Hi,
it's not a linking problem, it's a constraint of the Boost test
framework. Older versions allowed different tests to have the same name,
and we had a few of those in QuantLib. Since Boost 1.67 (which came out 7
years ago), that's no longer possible and we had to change those names.
This was fixed shortly afterwards in version 1.12.1.
If you can't upgrade at least to that version of QuantLib, you have two
possibilities. You can downgrade Boost to 1.66.0 and build with that, or
you can backport the fixes in <
https://github.com/lballabio/QuantLib/pull/446> to your version of QuantLib.
Hope this helps,
Luigi
On Thu, Feb 13, 2025 at 2:50 PM Amine Ifri <ami...@gm...> wrote:
> Hi Team,
>
> Hope you are well. I am reaching out as I am using an old version of
> QuantLib built with boost 1_83_0. The library builds fine as its own
> dynamic library target, and I build the suite of tests as a separate Target
> linking to the QuantLib dylib.
>
> The tests also build fine. However, when running the suite of tests, I get
> the following error message:
>
> *Test setup error: test unit with name
> 'QuantLib__detail__quantlib_test_case(boost__bind(&BasketOptionTest__testOneDAmericanValues_
> (i _(sizeof(oneDataValues)_sizeof(oneDataValues[0])))_nTestCases_
> ((i_1)_(sizeof(oneDataValues)_sizeof(oneDataValues[0])))_nTestCases))'
> registered multiple times in the test suite 'Basket option tests'*
>
> I use the preprocessing variable BOOST_TEST_DYN_LINK to enable the
> inclusion of the main function, but I don't use the parallel runner for the
> tests.
>
> Any suggestions on how to tackle this problem will be very much
> appreciated.
>
> Thanks,
> Amine
>
> _______________________________________________
> QuantLib-dev mailing list
> Qua...@li...
> https://lists.sourceforge.net/lists/listinfo/quantlib-dev
>
|
|
From: Amine I. <ami...@gm...> - 2025-02-13 13:49:22
|
Hi Team, Hope you are well. I am reaching out as I am using an old version of QuantLib built with boost 1_83_0. The library builds fine as its own dynamic library target, and I build the suite of tests as a separate Target linking to the QuantLib dylib. The tests also build fine. However, when running the suite of tests, I get the following error message: *Test setup error: test unit with name 'QuantLib__detail__quantlib_test_case(boost__bind(&BasketOptionTest__testOneDAmericanValues_ (i _(sizeof(oneDataValues)_sizeof(oneDataValues[0])))_nTestCases_ ((i_1)_(sizeof(oneDataValues)_sizeof(oneDataValues[0])))_nTestCases))' registered multiple times in the test suite 'Basket option tests'* I use the preprocessing variable BOOST_TEST_DYN_LINK to enable the inclusion of the main function, but I don't use the parallel runner for the tests. Any suggestions on how to tackle this problem will be very much appreciated. Thanks, Amine |
|
From: Luigi B. <lui...@gm...> - 2025-01-21 11:46:04
|
Ciao Paolo,
the cost of carry also needs to consider the dividend yield, in case
your test values include it as part of the inputs. If you want to open a
pull request with what you have at the moment, I'd be glad to have a look.
Hope this helps,
Luigi
On Mon, Jan 6, 2025 at 8:13 PM Paolo D'Elia <pao...@gm...> wrote:
> Dear QuantLib Developers,
>
> I hope this email finds you well. I’m currently working on implementing
> the feature request in issue #1986
> <https://github.com/lballabio/QuantLib/issues/1986>, which involves
> adding support for the calculation of partial-time put barrier options
> using the put-call symmetry approach as described on page 167 of Haug’s
> book (since there is no closed-form formula available). I’ve pushed my
> current work to the branch [partial-time-barrier-put-option]
> <https://github.com/paolodelia99/QuantLib/tree/partial-time-barrier-put-option>
> in my fork, and I would greatly appreciate your guidance on the following
> matters.
>
> So far, I’ve extended the AnalyticPartialTimeBarrierOptionEngine to
> support this feature. My implementation creates a synthetic call option and
> leverages the put-call symmetry to calculate the put price. While the code
> works in the context of the AnalyticPartialTimeBarrierOptionEngine, I
> wanted to verify its correctness by testing this same symmetry property on
> standard barrier options.
>
> Here is where I’m encountering an issue: for interest rate values
> different from 0, I observe a discrepancy in the put-call symmetry results.
> My suspicion is that I may not have properly accounted for the "cost of
> carry" term in the symmetry calculation. However, I’m struggling to fully
> understand this concept. I’ve read on page 8 of Haug’s book that, in the
> Black-Scholes model, the cost of carry is the same as the risk-free
> interest rate, but I can’t wrap my head around how it applies here or
> whether I’m omitting this variable in my implementation.
>
> Could this discrepancy be related to the cost-of-carry term, or am I
> misunderstanding something fundamental about the put-call symmetry for
> barrier options? If anyone has experience or insights into this area, I
> would be very grateful for your assistance and guidance.
>
> Thank you in advance for your time and help. Please let me know if further
> details or specific code snippets would be helpful.
>
> Best regards,
> Paolo D'Elia
> _______________________________________________
> QuantLib-dev mailing list
> Qua...@li...
> https://lists.sourceforge.net/lists/listinfo/quantlib-dev
>
|
|
From: Luigi B. <lui...@gm...> - 2025-01-21 09:57:57
|
QuantLib 1.37 is available for download at < https://www.quantlib.org/download.shtml>; precompiled binaries are also available from PyPI and NuGet for Python and C# respectively. The list of changes for this release is at < https://www.quantlib.org/reference/history.html>. If you have any problems with this release, please report them here on the QuantLib mailing list (<qua...@li...>) or open a GitHub issue at <https://github.com/lballabio/quantlib/issues>. |
|
From: Paolo D'E. <pao...@gm...> - 2025-01-06 19:12:15
|
Dear QuantLib Developers, I hope this email finds you well. I’m currently working on implementing the feature request in issue #1986 <https://github.com/lballabio/QuantLib/issues/1986>, which involves adding support for the calculation of partial-time put barrier options using the put-call symmetry approach as described on page 167 of Haug’s book (since there is no closed-form formula available). I’ve pushed my current work to the branch [partial-time-barrier-put-option] <https://github.com/paolodelia99/QuantLib/tree/partial-time-barrier-put-option> in my fork, and I would greatly appreciate your guidance on the following matters. So far, I’ve extended the AnalyticPartialTimeBarrierOptionEngine to support this feature. My implementation creates a synthetic call option and leverages the put-call symmetry to calculate the put price. While the code works in the context of the AnalyticPartialTimeBarrierOptionEngine, I wanted to verify its correctness by testing this same symmetry property on standard barrier options. Here is where I’m encountering an issue: for interest rate values different from 0, I observe a discrepancy in the put-call symmetry results. My suspicion is that I may not have properly accounted for the "cost of carry" term in the symmetry calculation. However, I’m struggling to fully understand this concept. I’ve read on page 8 of Haug’s book that, in the Black-Scholes model, the cost of carry is the same as the risk-free interest rate, but I can’t wrap my head around how it applies here or whether I’m omitting this variable in my implementation. Could this discrepancy be related to the cost-of-carry term, or am I misunderstanding something fundamental about the put-call symmetry for barrier options? If anyone has experience or insights into this area, I would be very grateful for your assistance and guidance. Thank you in advance for your time and help. Please let me know if further details or specific code snippets would be helpful. Best regards, Paolo D'Elia |