|
From: Wei Li <ttl...@gm...> - 2024-03-28 10:45:52
|
Dear all, I am trying to bootstrap a currency interest rate curve with a base currency curve and a set of FX forward point quotes. So I am generating a list of FxSwapRateHelper objects, each would have a forward point quote, a fx spot quote, a tenor and some other properties. For example, I have a USD curve already, a 6M forward point quote of 85 for EURUSD, and the fx spot quote is 1.084, The fixing lag is 2 business days. I would then generate this rate helper like this: instrument = ql.FxSwapRateHelper(ql.QuoteHandle(ql.SimpleQuote(85/10000)), ql.SimpleQuote(1.084)), ql.Period(6, ql.Months), 2, ql.JointCalendar(ql.UnitedStates(), ql.TARGET()), ql.Following, IS_SPOT_DATE_END_OF_MONTH, False, USD_CURVE) The USD_CURVE is the IR curve for USD that I already have. And the FX forward convention is if the spot date (T+2) is the end of its month, then all maturity date of forwards must also be the end of months, hence the IS_SPOT_DATE_END_OF_MONTH parameter. Now I am having trouble on how to decide the T+2 / spot date. Because from what I learned, the convention is if T+1 is a US holiday and T+2 is not, then the T+2 day is the spot day. But if T+1 is not a US holiday and yet an EU holiday, then we use the T+3, My description might not be accurate since when we say +1, +2 we would mean business day already. So let me use some examples: case 1: if today is 20240112 Friday, and next Monday 20240115 is Martin Luther King Jr. day, which is a holiday in US but not in EU, then the spot date would be the next business day of 20240115 which is 20240116. case 2: if today is 20240111 Thursday, the spot day would also be 20240116 since the "normal" T+2 is Martin Luther King Jr. day. case 3: if today is 20240430 Tuesday, 20240501 is Labour day which is an EU holiday but not one in US, then the spot day is 20240503. Now I can't handle the case 1 using the code I gave above, since the joint calendar always takes all holidays in both US and EU, so it would give 20240117. Is there any way that I can handle this kind of convention? Thank you very much! Cheers, Wei |