Main Content

cdsoptprice

Price payer and receiver credit default swap options

Description

[Payer,Receiver] = cdsoptprice(ZeroData,ProbData,Settle,OptionMaturity,CDSMaturity,Strike,SpreadVol) computes the price of payer and receiver credit default swap options.

Note

Alternatively, you can use the CDSOption object to price credit default swap options. For more information, see Get Started with Workflows Using Object-Based Framework for Pricing Financial Instruments.

example

[Payer,Receiver] = cdsoptprice(___,Name,Value) computes the price of payer and receiver credit default swap options with additional options specified by one or more Name,Value pair arguments.

example

Examples

collapse all

Use cdsoptprice to generate Payer and Receiver values for a credit default swap option.

Settle = datenum('12-Jun-2012');
OptionMaturity = datenum('20-Sep-2012');
CDSMaturity = datenum('20-Sep-2017');
OptionStrike = 200;
SpreadVolatility = .4;

Zero_Time = [.5 1 2 3 4 5]';
Zero_Rate = [.5 .75 1.5 1.7 1.9 2.2]'/100;
Zero_Dates = daysadd(Settle,360*Zero_Time,1);
ZeroData = [Zero_Dates Zero_Rate];

Market_Time = [1 2 3 5 7 10]';
Market_Rate = [100 120 145 220 245 270]';
Market_Dates = daysadd(Settle,360*Market_Time,1);
MarketData = [Market_Dates Market_Rate];

ProbData = cdsbootstrap(ZeroData, MarketData, Settle);

[Payer,Receiver] = cdsoptprice(ZeroData, ProbData, Settle,...
OptionMaturity, CDSMaturity, OptionStrike, SpreadVolatility)
Payer = 
223.5780
Receiver = 
22.7460

Input Arguments

collapse all

Zero rates, specified by using a M-by-2 vector of dates and zero rates or an IRDataCurve object of zero rates. For more information on an IRDataCurve object, see Creating an IRDataCurve Object..

Data Types: double | object

Probability of default, specified as a P-by-2 array of dates and default probabilities.

Data Types: double

Settlement date, specified as a scalar using a serial nonnegative date number or date character vector. Settle must be earlier than the OptionMaturity date.

Data Types: double | char

Option maturity dates, specified as an NINST-by-1 vector using a serial nonnegative date number or date character vector.

Data Types: double | char

CDS maturity dates, specified as an NINST-by-1 vector using a serial nonnegative date number or date character vector.

Data Types: double | char

Option strikes in basis points, specified as an NINST-by-1 vector.

Data Types: double

Annualized credit spread volatilities, specified an NINST-by-1 vector of positive decimals.

Data Types: double

Name-Value Arguments

Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

Before R2021a, use commas to separate each name and value, and enclose Name in quotes.

Example: [Payer,Receiver] = cdsoptprice(ZeroData,ProbData,Settle,OptionMaturity,CDSMaturity,OptionStrike,SpreadVolatility)

Adjusted forward spread in basis points, specified as the comma-separated pair consisting of 'AdjustedForwardSpread' and an NINST-by-1 vector.

Data Types: double

Day count basis, specified as the comma-separated pair consisting of 'Basis' and an NINST-by-1 vector.

  • 0 = actual/actual

  • 1 = 30/360 (SIA)

  • 2 = actual/360

  • 3 = actual/365

  • 4 = 30/360 (PSA)

  • 5 = 30/360 (ISDA)

  • 6 = 30/360 (European)

  • 7 = actual/365 (Japanese)

  • 8 = actual/actual (ICMA)

  • 9 = actual/360 (ICMA)

  • 10 = actual/365 (ICMA)

  • 11 = 30/360E (ICMA)

  • 12 = actual/365 (ISDA)

  • 13 = BUS/252

For more information, see Basis.

Data Types: double

Business day conventions, specified as the comma-separated pair consisting of 'BusinessDayConvention' and a character vector or a N-by-1 cell array of character vectors of business day conventions. The selection for business day convention determines how non-business days are treated. Non-business days are defined as weekends plus any other date that businesses are not open (e.g. statutory holidays). Values are:

  • actual — Non-business days are effectively ignored. Cash flows that fall on non-business days are assumed to be distributed on the actual date.

  • follow — Cash flows that fall on a non-business day are assumed to be distributed on the following business day.

  • modifiedfollow — Cash flows that fall on a non-business day are assumed to be distributed on the following business day. However if the following business day is in a different month, the previous business day is adopted instead.

  • previous — Cash flows that fall on a non-business day are assumed to be distributed on the previous business day.

  • modifiedprevious — Cash flows that fall on a non-business day are assumed to be distributed on the previous business day. However if the previous business day is in a different month, the following business day is adopted instead.

Data Types: char | cell

Indicator of knockout, specified as the comma-separated pair consisting of 'Knockout' and an NINST-by-1 vector of boolean flags. If the credit default swaptions is a knockout, the flag is True, otherwise it is False.

Data Types: logical

Indicator of accrued premium, specified as the comma-separated pair consisting of 'PayAccruedPremium' and an NINST-by-1 vector of boolean flags. If accrued premiums are paid upon default, the flag is True, otherwise it is False.

Data Types: logical

Premiums per year of CDS, specified as the comma-separated pair consisting of 'Period' and a NINST-by-1 vector. Allowed values are 1, 2, 3, 4, 6, and 12.

Data Types: double

Recovery rates, specified as the comma-separated pair consisting of 'RecoveryRate' and a NINST-by-1 vector of decimal values from 0 to 1.

Data Types: double

Basis of zero curve, specified as the comma-separated pair consisting of 'ZeroBasis' and an NINST-by-1 vector.

  • 0 = actual/actual

  • 1 = 30/360 (SIA)

  • 2 = actual/360

  • 3 = actual/365

  • 4 = 30/360 (PSA)

  • 5 = 30/360 (ISDA)

  • 6 = 30/360 (European)

  • 7 = actual/365 (Japanese)

  • 8 = actual/actual (ICMA)

  • 9 = actual/360 (ICMA)

  • 10 = actual/365 (ICMA)

  • 11 = 30/360E (ICMA)

  • 12 = actual/365 (ISDA)

  • 13 = BUS/252

For more information, see Basis.

Data Types: double

Compounding frequency of zero curve, specified as the comma-separated pair consisting of 'ZeroCompounding' and an integer with one of the following allowed values:

  • 1 — Annual compounding

  • 2 — Semiannual compounding

  • 3 — Compounding three times per year

  • 4 — Quarterly compounding

  • 6 — Bimonthly compounding

  • 12 — Monthly compounding

  • −1 — Continuous compounding

Note

When ZeroData is an IRDataCurve object, the arguments ZeroCompounding and ZeroBasis are implicit in ZeroData and are redundant inside this function. In that case, specify these optional arguments when constructing the IRDataCurve object before calling this function.

Data Types: double

Output Arguments

collapse all

Payer swap options in Basis points, returned as an NINST-by-1 vector of prices.

Receiver swap options in Basis points, returned as an NINST-by-1 vector of prices.

More About

collapse all

Credit Default Swap Option

A credit default swap (CDS) option, or credit default swaption, is a contract that provides the option holder with the right, but not the obligation, to enter into a credit default swap in the future.

CDS options can either be payer swaptions or receiver swaptions. In a payer swaption, the option holder has the right to enter into a CDS in which they are paying premiums and in a receiver swaption, the option holder is receiving premiums.

Algorithms

The payer and receiver credit default swap options are computed using the Black's model as described in O'Kane [1]:

VPay(Knockout)=RPV01(t,tE,T)(FΦ(d1)KΦ(d2))

VRec(Knockout)=RPV01(t,tE,T)(KΦ(d2)FΦ(d1))

d1=ln(FK)+12σ2(tEt)σtEt

d2=d1σtEt

VPay(NonKnockout)=VPay(Knockout)+FEP

VPay(NonKnockout)=VRec(Knockout)

where

RPV01 is the risky present value of a basis point (see cdsrpv01).

Φ is the normal cumulative distribution function.

σ is the spread volatility.

t is the valuation date.

tE is the option expiry date.

T is the CDS maturity date.

F is the forward spread (from option expiry to CDS maturity).

K is the strike spread.

FEP is the front-end protection (from option initiation to option expiry).

References

[1] O'Kane, D. Modelling Single-name and Multi-name Credit Derivatives. Wiley, 2008, pp. 156–169.

Version History

Introduced in R2011a