Financial Derivatives Toolbox | ![]() ![]() |
Price bond option by HJM interest rate tree
Syntax
[Price, PriceTree] = optbndbyhjm(HJMTree, OptSpec, Strike, ExerciseDates, AmericanOpt, CouponRate, Settle, Maturity, Period, Basis, EndMonthRule, IssueDate, FirstCouponDate, LastCouponDate, StartDate, Face, Options)
Arguments
HJMTree |
Forward rate tree structure created by hjmtree . |
OptSpec |
Number of instruments (NINST) -by-1 cell array of string values 'Call' or 'Put' . |
Strike |
For a European or Bermuda option: Number of instruments ( NINST ) by number of strikes (NSTRIKES ) matrix of strike price values. Each row is the schedule for one option. If an option has fewer than NSTRIKES exercise opportunities, the end of the row is padded with NaN s.For an American option: NINST -by-1 vector of strike price values for each option. |
ExerciseDates |
For a European or Bermuda option:NINST -by-NSTRIKES matrix of exercise dates. Each row is the schedule for one option. A European option has only one exercise date, the option expiry date.For an American option: NINST -by-2 vector of exercise date boundaries. For each instrument, the option can be exercised on any coupon date between or including the pair of dates on that row. If only one non-NaN date is listed, or if ExerciseDates is NINST -by-1 , the option can be exercised between the underlying bond Settle and the single listed exercise date. |
AmericanOpt |
NINST -by-1 vector of flags: 0 (European/Bermuda) or 1 (American). |
CouponRate |
Decimal annual rate. |
Settle |
Settlement date. A vector of serial date numbers or date strings. Settle must be earlier than or equal to Maturity . |
Maturity |
Maturity date. A vector of serial date numbers or date strings. |
Period |
(Optional) Coupons per year of the bond. A vector of integers. Allowed values are 1 , 2 , 3 , 4 , 6 , and 12 . Default = 2 . |
Basis | (Optional) Day-count basis of the bond. A vector of integers.0 = actual/actual (default), 1 = 30/360, 2 = actual/360, 3 = actual/365. |
EndMonthRule |
(Optional) End-of-month rule. A vector. This rule applies only when Maturity is an end-of-month date for a month having 30 or fewer days. 0 = ignore rule, meaning that a bond's coupon payment date is always the same numerical day of the month. 1 = set rule on (default), meaning that a bond's coupon payment date is always the last actual day of the month. |
IssueDate |
(Optional) Date when a bond was issued. |
FirstCouponDate |
(Optional) Date when a bond makes its first coupon payment. When FirstCouponDate and LastCouponDate are both specified, FirstCouponDate takes precedence in determining the coupon payment structure. |
LastCouponDate |
(Optional) Last coupon date of a bond prior to the maturity date. In the absence of a specified FirstCouponDate , a specified LastCouponDate determines the coupon structure of the bond. The coupon structure of a bond is truncated at the LastCouponDate regardless of where it falls and is followed only by the bond's maturity cash flow date. |
StartDate |
Ignored. |
Face |
(Optional) Face value. Default = 100 . |
Options |
(Optional) Derivatives pricing options structure created with derivset . |
The Settle
date for every bond is set to the ValuationDate
of the HJM tree. The bond argument Settle
is ignored.
Description
[Price, PriceTree] = optbndbyhjm(HJMTree, OptSpec, Strike,
ExerciseDates, AmericanOpt, CouponRate, Settle, Maturity, Period,
Basis, EndMonthRule, IssueDate, FirstCouponDate, LastCouponDate,
StartDate, Face, Options)
computes the price of a bond option from an HJM forward rate tree.
Price
is an NINST
-by-1
matrix of expected prices at time 0.
PriceTree
is a tree structure with a vector of instrument prices at each node.
Examples
Using the HJM forward rate tree in the deriv.mat
file, price a European call option on a 4% bond with a strike of 96. The exercise date for the option is Jan. 01, 2003. The settle date for the bond is Jan. 01, 2000, and the maturity date is Jan. 01, 2004.
Load the file deriv.mat
, which provides HJMTree
. HJMTree
contains the time and forward rate information needed to price the bond.
Use optbondbyhjm
to compute the price of the option.
Price = optbndbyhjm(HJMTree,'Call','96','01-Jan-2003',... '0','0.04','01-Jan-2000','01-Jan-2004') Warning: Not all cash flows are aligned with the tree. Result will be approximated. Price = 2.2410
See Also
![]() | optbndbybdt | rate2disc | ![]() |