I am new to quantlib, but I have relatively good understanding of C++. To put my question in some sort of context, I can inform you that I am actually trying to implement the portfolio CVA calculation method proposed by Giovanni Cesari (see link below) for a simple portfolio consisting of one interest rate swap (as a starting point).
I working with the Cheyette (quasi-Gaussian) interest rate model. The model has been implemented as a "new" stochastic process class and the simulated paths stored/generated as a multipath class. However, as Cesari's method is based on LS-Monte Carlo, I need to write a code that can generate the resulting cash flow sequence from an interest rate swap under each scenario. I do not know if there is some efficient way to do this in quantlib, but I have a feeling that there is. I guess one should be able let the scenarios generated, populate Quantlib quotes which are linked to an instance of the quantlib term structures class. Hopefully I can use this together with the swap class in order to obtain the realized cash flows (basically the floating leg, as the fixed leg is deterministic) from the swap. Any idea of how this can be done will be highly appreciated! Link to Cesari's presentation (see page 21 to 26): http://sfi.epfl.ch/files/content/sites/sfi/files/shared/Swissquote%20Conference%202010/Cesari_talk.pdf |
You can generate future rates and link them to the term-structure handle that you used to build your cashflows. Matthias Groncki just posted something like this on his blog: <https://ipythonquant.wordpress.com/2015/04/08/expected-exposure-and-pfe-simulation-with-quantlib-and-python/>. In the example he uses a flat term structure for convenience, but you can just as well use an interpolated curve. Luigi On Thu, Apr 9, 2015 at 7:54 PM, vegardde <[hidden email]> wrote: I am new to quantlib, but I have relatively good understanding of C++. To put ------------------------------------------------------------------------------ BPM Camp - Free Virtual Workshop May 6th at 10am PDT/1PM EDT Develop your own process in accordance with the BPMN 2 standard Learn Process modeling best practices with Bonita BPM through live exercises http://www.bonitasoft.com/be-part-of-it/events/bpm-camp-virtual- event?utm_ source=Sourceforge_BPM_Camp_5_6_15&utm_medium=email&utm_campaign=VA_SF _______________________________________________ QuantLib-users mailing list [hidden email] https://lists.sourceforge.net/lists/listinfo/quantlib-users |
Free forum by Nabble | Edit this page |