http://quantlib.414.s1.nabble.com/question-on-YieldTermStructure-forwardRate-tp14955p14959.html
> Thanks, Toby.
>
> What I really want to know is whether there is a more elegant way to
> calculate the fairRate for the swap without having to build the whole
> swap object (fixed schedule, float schedule, fakeNotional,
> fakeCoupon).
>
> All I really want to do is ask QL,
> given this discount curve, and these conventions (Semi, vs 3mL) what
> is the fair rate of the swap?
>
> I realize that building out the swap is in fact giving QL the
> definitive conventions, but it all seems a bit cumbersome to build a
> swap w/ a fake coupon, just to pull the 'fairRate' back out of it.
>
> -Whit
>
>
> On Tue, Feb 11, 2014 at 2:08 PM, Nils Tobias Kramer
> <
[hidden email]> wrote:
>> Hi Whit,
>>
>> Maybe I'm misunderstanding you and I didn't look at the code.
>>
>> FRA is a single forward rate calculated by two discount factors on the same curve and a swap par rate is a bit more complex to calculate. You have two curves to calculate, the first to get the forward rates and then a second to discount your cashflows. You can check wikipedia to see how the fair rate of a swap is calculated.
>>
>> Toby
>>
>>> On 11.02.2014, at 19:29, Whit Armstrong <
[hidden email]> wrote:
>>>
>>> I have a question on the forwardRate function of YieldTermStructure.
>>>
>>> When I bootstrap a yield curve and calc the 5yr5yr forward rate using
>>> the forwardRate function, it does not match the 'fairRate' calculated
>>> from an actual VanillaSwap object using the same forward dates.
>>>
>>> Is this expected, and if so, is there something I can do to my
>>> forwardRate call to adjust the rate to match the par swap rate of the
>>> forward dates?
>>>
>>> See this link for an example which prints both rates.
>>>
>>> The rate calculated from the forwardRate function is consistently
>>> higher over historical dates (by about 1.5 bpts) than the rate
>>> calculated by the fairRate function.
>>>
>>> Any insight would be much appreciated.
>>>
>>> -Whit
>>>
>>>
>>>
https://gist.github.com/armstrtw/8940881>>>
>>> ------------------------------------------------------------------------------
>>> Android apps run on BlackBerry 10
>>> Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
>>> Now with support for Jelly Bean, Bluetooth, Mapview and more.
>>> Get your Android app in front of a whole new audience. Start now.
>>>
http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk>>> _______________________________________________
>>> QuantLib-users mailing list
>>>
[hidden email]
>>>
https://lists.sourceforge.net/lists/listinfo/quantlib-users>
> ------------------------------------------------------------------------------
> Android apps run on BlackBerry 10
> Introducing the new BlackBerry 10.2.1 Runtime for Android apps.
> Now with support for Jelly Bean, Bluetooth, Mapview and more.
> Get your Android app in front of a whole new audience. Start now.
>
http://pubads.g.doubleclick.net/gampad/clk?id=124407151&iu=/4140/ostg.clktrk> _______________________________________________
> QuantLib-users mailing list
>
[hidden email]
>
https://lists.sourceforge.net/lists/listinfo/quantlib-usersGet your Android app in front of a whole new audience. Start now.