Payoffs

Overview

functions to construct and use StrikedTypePayoff and DoubleStickyRatchetPayoff objects.

Function List

qlDoubleStickyRatchetPayoff ()
qlPayoffDescription ()
qlPayoffName ()
qlPayoffOptionType ()
qlPayoffStrike ()
qlPayoffThirdParameter ()
qlPayoffValue ()
qlRatchetMaxPayoff ()
qlRatchetMinPayoff ()
qlRatchetPayoff ()
qlStickyMaxPayoff ()
qlStickyMinPayoff ()
qlStickyPayoff ()
qlStrikedTypePayoff ()

Function Documentation

qlDoubleStickyRatchetPayoff

string returnValue
qlDoubleStickyRatchetPayoff(
string ObjectId
double Type1
double Type2
double Gearing1
double Gearing2
double Gearing3
double Spread1
double Spread2
double Spread3
double InitialValue1
double InitialValue2
double AccrualFactor
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class DoubleStickyRatchetPayoff and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
Type1Sticky (type1=1) or Ratchet (type1=-1) payoff .
Type2Strike type (type2=1 for Min, type2=-1 for Max, type2=0 for single sticky/ratchet) .
Gearing1gearing 1 (for strike 1).
Gearing2gearing 2 (for strike 2).
Gearing3gearing 3 (for forward rate 3).
Spread1spread 1 (for strike 1).
Spread2spread 2 (for strike 2).
Spread3spread 3 (for forward rate 3).
InitialValue1initial value for strike 1 (forward rate or coupon/accrualFactor).
InitialValue2initial value for strike 2 (forward rate or coupon/accrualFactor).
AccrualFactoraccrual factor.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlPayoffDescription

string returnValue
qlPayoffDescription(
string ObjectId
any Trigger)
Description:

returns the description (e.g. CashOrNothing, strike 32.2, cash payoff 2.5) for the given Payoff object.

Supported Platforms:

Excel

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

qlPayoffName

string returnValue
qlPayoffName(
string ObjectId
any Trigger)
Description:

returns the type (e.g. Vanilla, CashOrNothing, etc.) for the given Payoff object.

Supported Platforms:

Excel

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

qlPayoffOptionType

string returnValue
qlPayoffOptionType(
string ObjectId
any Trigger)
Description:

returns the option-type (e.g. Call, Put) for the given Payoff object.

Supported Platforms:

Excel

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

qlPayoffStrike

double returnValue
qlPayoffStrike(
string ObjectId
any Trigger)
Description:

returns the strike for the given Payoff object.

Supported Platforms:

Excel

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

qlPayoffThirdParameter

double returnValue
qlPayoffThirdParameter(
string ObjectId
any Trigger)
Description:

returns the third parameter of a StrikedType payoff.

Supported Platforms:

Excel

Parameters
ObjectIdid of existing QuantLibAddin::StrikedTypePayoff object
Triggerdependency tracking trigger

qlPayoffValue

double returnValue
qlPayoffValue(
string ObjectId
double Underlying
any Trigger)
Description:

returns the payoff value given an underlying reference level for the given Payoff object.

Supported Platforms:

Excel

Parameters
ObjectIdid of existing QuantLib::Payoff object
Underlyingunderlying reference level.
Triggerdependency tracking trigger

qlRatchetMaxPayoff

string returnValue
qlRatchetMaxPayoff(
string ObjectId
double Gearing1
double Gearing2
double Gearing3
double Spread1
double Spread2
double Spread3
double InitialValue1
double InitialValue2
double AccrualFactor
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class RatchetMaxPayoff and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
Gearing1gearing 1 (for strike 1).
Gearing2gearing 2 (for strike 2).
Gearing3gearing 3 (for forward rate 3).
Spread1spread 1 (for strike 1).
Spread2spread 2 (for strike 2).
Spread3spread 3 (for forward rate 3).
InitialValue1initial value for strike 1 (forward rate or coupon/accrualFactor).
InitialValue2initial value for strike 2 (forward rate or coupon/accrualFactor).
AccrualFactoraccrual factor.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlRatchetMinPayoff

string returnValue
qlRatchetMinPayoff(
string ObjectId
double Gearing1
double Gearing2
double Gearing3
double Spread1
double Spread2
double Spread3
double InitialValue1
double InitialValue2
double AccrualFactor
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class RatchetMinPayoff and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
Gearing1gearing 1 (for strike 1).
Gearing2gearing 2 (for strike 2).
Gearing3gearing 3 (for forward rate 3).
Spread1spread 1 (for strike 1).
Spread2spread 2 (for strike 2).
Spread3spread 3 (for forward rate 3).
InitialValue1initial value for strike 1 (forward rate or coupon/accrualFactor).
InitialValue2initial value for strike 2 (forward rate or coupon/accrualFactor).
AccrualFactoraccrual factor.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlRatchetPayoff

string returnValue
qlRatchetPayoff(
string ObjectId
double Gearing1
double Gearing2
double Spread1
double Spread2
double InitialValue
double AccrualFactor
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class RatchetPayoff and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
Gearing1gearing 1 (for strike 1).
Gearing2gearing 2 (for strike 2).
Spread1spread 1 (for strike 1).
Spread2spread 2 (for strike 2).
InitialValueinitial value for strike (forward rate or coupon/accrualFactor).
AccrualFactoraccrual factor.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlStickyMaxPayoff

string returnValue
qlStickyMaxPayoff(
string ObjectId
double Gearing1
double Gearing2
double Gearing3
double Spread1
double Spread2
double Spread3
double InitialValue1
double InitialValue2
double AccrualFactor
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class StickyMaxPayoff and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
Gearing1gearing 1 (for strike 1).
Gearing2gearing 2 (for strike 2).
Gearing3gearing 3 (for forward rate 3).
Spread1spread 1 (for strike 1).
Spread2spread 2 (for strike 2).
Spread3spread 3 (for forward rate 3).
InitialValue1initial value for strike 1 (forward rate or coupon/accrualFactor).
InitialValue2initial value for strike 2 (forward rate or coupon/accrualFactor).
AccrualFactoraccrual factor.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlStickyMinPayoff

string returnValue
qlStickyMinPayoff(
string ObjectId
double Gearing1
double Gearing2
double Gearing3
double Spread1
double Spread2
double Spread3
double InitialValue1
double InitialValue2
double AccrualFactor
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class StickyMinPayoff and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
Gearing1gearing 1 (for strike 1).
Gearing2gearing 2 (for strike 2).
Gearing3gearing 3 (for forward rate 3).
Spread1spread 1 (for strike 1).
Spread2spread 2 (for strike 2).
Spread3spread 3 (for forward rate 3).
InitialValue1initial value for strike 1 (forward rate or coupon/accrualFactor).
InitialValue2initial value for strike 2 (forward rate or coupon/accrualFactor).
AccrualFactoraccrual factor.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlStickyPayoff

string returnValue
qlStickyPayoff(
string ObjectId
double Gearing1
double Gearing2
double Spread1
double Spread2
double InitialValue
double AccrualFactor
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class StickyPayoff and return its id

Supported Platforms:

Excel, C++

Parameters
ObjectIdid of object to be created
Gearing1gearing 1 (for strike 1).
Gearing2gearing 2 (for strike 2).
Spread1spread 1 (for strike 1).
Spread2spread 2 (for strike 2).
InitialValueinitial value for strike (forward rate or coupon/accrualFactor).
AccrualFactoraccrual factor.
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag

qlStrikedTypePayoff

string returnValue
qlStrikedTypePayoff(
string ObjectId
string PayoffID
string OptionType
double Strike
double ThirdParameter
bool Permanent
any Trigger
bool Overwrite)
Description:

Construct an object of class StrikedTypePayoff and return its id

Supported Platforms:

Excel, C, Calc, Guile, C++

Parameters
ObjectIdid of object to be created
PayoffIDpayoff ID (e.g. Vanilla, PercentageStrike, AssetOrNothing, CashOrNothing, Gap, SuperShare).
OptionTypeoption type.
Strikestrike.
ThirdParameterthe 3rd paramenter for the payoff definition of CashOrNothing (cash), Gap (determines the size of the payoff), SuperFund (second strike). Default value = QuantLib::Null<QuantLib::Real>().
Permanentobject permanent/nonpermanent
Triggerdependency tracking trigger
Overwriteoverwrite flag