Main Content

bdtsens

Instrument prices and sensitivities from Black-Derman-Toy interest-rate tree

Description

[Delta,Gamma,Vega,Price] = bdtsens(BDTTree,InstSet) computes instrument sensitivities and prices for instruments using an interest-rate tree created with the bdttree function. All sensitivities are returned as dollar sensitivities. To find the per-dollar sensitivities, divide by the respective instrument price.

bdtsens handles instrument types: 'Bond', 'CashFlow', 'OptBond', 'OptEmBond', 'OptEmBond', 'OptFloat', 'OptEmFloat', 'Fixed', 'Float', 'Cap', 'Floor', 'RangeFloat', 'Swap'. See instadd for information on instrument types.

example

[Delta,Gamma,Vega,Price] = bdtsens(___,Options) adds an optional input argument for Options.

example

Examples

collapse all

Load the tree and instruments from the deriv.mat data file.

load deriv.mat; 
BDTSubSet = instselect(BDTInstSet,'Type', {'Float', 'Cap'});  
 
instdisp(BDTSubSet)
Index Type  Spread Settle         Maturity       FloatReset Basis Principal Name       Quantity
1     Float 20     01-Jan-2000    01-Jan-2003    1          NaN   NaN       20BP Float 8       
 
Index Type Strike Settle         Maturity       CapReset Basis Principal Name    Quantity
2     Cap  0.15   01-Jan-2000    01-Jan-2004    1        NaN   NaN       15% Cap 30      
 

Compute Delta and Gamma for the cap and float instruments contained in the instrument set.

[Delta, Gamma] = bdtsens(BDTTree, BDTSubSet)
Delta = 2×1

   -0.8392
   63.8102

Gamma = 2×1
103 ×

    0.0025
    1.8535

Input Arguments

collapse all

Interest-rate tree structure, specified by using bdttree.

Data Types: struct

Instrument variable containing a collection of NINST instruments, specified using instadd. Instruments are categorized by type; each type can have different data fields. The stored data field is a row vector or character vector for each instrument.

Data Types: struct

(Optional) Derivatives pricing options structure, created using derivset.

Data Types: struct

Output Arguments

collapse all

Rate of change of instruments prices with respect to changes in the interest rate, returned as a NINST-by-1 vector of deltas. Delta is computed by finite differences in calls to bdttree.

Note

Delta is calculated based on yield shifts of 100 basis points.

Rate of change of instruments deltas with respect to changes in the interest rate, returned as a NINST-by-1 vector of gammas. Gamma is computed by finite differences in calls to bdttree.

Note

Gamma is calculated based on yield shifts of 100 basis points.

Rate of change of instruments prices with respect to changes in the volatility, returned as a NINST-by-1 vector of vegas. Volatility is σ(t,T) of the interest rate. Vega is computed by finite differences in calls to bdttree. For information on the volatility process, see bdtvolspec.

Note

Vega is calculated based on 1% shift in the volatility process.

Price of each instrument, returned as a NINST-by-1 vector. The prices are computed by backward dynamic programming on the interest-rate tree. If an instrument cannot be priced, a NaN is returned in that entry.

Version History

Introduced before R2006a