| Financial Derivatives Toolbox | ![]() |
www.kxcad.net Home > CAE Software Index > MATLAB Index >
Construct BDT interest-rate tree
BDTTree = bdttree(VolSpec, RateSpec,
TimeSpec)
VolSpec | Volatility process specification. See bdtvolspec for information on the volatility process. |
RateSpec | Interest-rate specification for the initial rate curve. See intenvset for information on declaring an interest-rate variable. |
TimeSpec | Tree time layout specification. Defines the observation dates of the BDT tree and the Compounding rule for date to time mapping and price-yield formulas. See bdttimespec for information on the tree structure. |
BDTTree = bdttree(VolSpec, RateSpec, TimeSpec) creates a structure containing time and interest-rate information on a recombining tree.
Using the data provided, create a BDT volatility specification (VolSpec), rate specification (RateSpec), and tree time layout specification (TimeSpec). Then use these specifications to create a BDT tree with bdttree.
Compounding = 1;
ValuationDate = '01-01-2000';
StartDate = ValuationDate;
EndDates = ['01-01-2001'; '01-01-2002'; '01-01-2003';
'01-01-2004'; '01-01-2005'];
Rates = [.1; .11; .12; .125; .13];
Volatility = [.2; .19; .18; .17; .16];
RateSpec = intenvset('Compounding', Compounding,...
'ValuationDate', ValuationDate,...
'StartDates', StartDate,...
'EndDates', EndDates,...
'Rates', Rates);
BDTTimeSpec = bdttimespec(ValuationDate, EndDates, Compounding);
BDTVolSpec = bdtvolspec(ValuationDate, EndDates, Volatility);
BDTTree = bdttree(BDTVolSpec, RateSpec, BDTTimeSpec);
Use treeviewer to observe the tree you have created.
treeviewer(BDTTree)

bdtprice, bdttimespec, bdtvolspec, intenvset
| bdttimespec | bdtvolspec | ![]() |
© 1984-2007 The MathWorks, Inc. Terms of Use Patents Trademarks Acknowledgments