Swap

Overview

functions to construct and use Swap objects.

Function List

qlMakeCms ()
qlSwap ()
qlSwapLegAnalysis ()
qlSwapLegBPS ()
qlSwapLegNPV ()
qlSwapMaturityDate ()
qlSwapNumberOfLegs ()
qlSwapStartDate ()

Function Documentation

qlMakeCms

string returnValue
qlMakeCms(
string ObjectId
string SwapTenor
string SwapIndex
string IborIndex
double IborSpread
string ForwardStart
string CmsCouponPricer
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class Swap and return its id

Supported Platforms:

Excel, C++, Calc

Parameters
ObjectIdid of object to be created
SwapTenorswap tenor period.
SwapIndexSwapIndex object ID.
IborIndexIborIndex object ID.
IborSpreadspread over the ibor leg. Default value = QuantLib::Null<QuantLib::Spread>().
ForwardStartforward start period.
CmsCouponPricerCmsCouponPricer object ID.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlSwap

string returnValue
qlSwap(
string ObjectId
vector<string> LegIDs
vector<bool> Payer
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class Swap and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
LegIDsleg object IDs.
PayerTRUE for payed leg.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlSwapLegAnalysis

vector<vector<any> > returnValue
qlSwapLegAnalysis(
string ObjectId
long LegNumber
long AfterDate
any Trigger)
Description:

Returns the cash flow analysis of the i-th leg for the given Swap object.

Supported Platforms:

Excel

Parameters
ObjectIdid of existing QuantLibAddin::Swap object
LegNumberZero based leg number (e.g. use 0 for the first leg, 1 for the second leg, etc.).
AfterDateShows only cashflows after given date Default value = QuantLib::Date().
Triggerdependency tracking trigger

qlSwapLegBPS

double returnValue
qlSwapLegBPS(
string ObjectId
long LegNumber
any Trigger)
Description:

returns the BPS of the i-th leg for the given Swap object.

Supported Platforms:

Excel, Calc

Parameters
ObjectIdid of existing QuantLib::Swap object
LegNumberZero based leg number (e.g. use 0 for the first leg, 1 for the second leg, etc.).
Triggerdependency tracking trigger

qlSwapLegNPV

double returnValue
qlSwapLegNPV(
string ObjectId
long LegNumber
any Trigger)
Description:

returns the NPV of the i-th leg for the given Swap object.

Supported Platforms:

Excel, Calc

Parameters
ObjectIdid of existing QuantLib::Swap object
LegNumberZero based leg number (e.g. use 0 for the first leg, 1 for the second leg, etc.).
Triggerdependency tracking trigger

qlSwapMaturityDate

long returnValue
qlSwapMaturityDate(
string ObjectId
any Trigger)
Description:

Returns the maturity (i.e. last payment) date for the given Swap object.

Supported Platforms:

Excel, Calc

Parameters
ObjectIdid of existing QuantLib::Swap object
Triggerdependency tracking trigger

qlSwapNumberOfLegs

double returnValue
qlSwapNumberOfLegs(
string ObjectId
any Trigger)
Description:

returns the number of legs for the given Swap object.

Supported Platforms:

Excel, Calc

Parameters
ObjectIdid of existing QuantLib::Swap object
Triggerdependency tracking trigger

qlSwapStartDate

long returnValue
qlSwapStartDate(
string ObjectId
any Trigger)
Description:

Returns the start (i.e. first accrual) date for the given Swap object.

Supported Platforms:

Excel, Calc

Parameters
ObjectIdid of existing QuantLib::Swap object
Triggerdependency tracking trigger