optbndbybk
Price bond option from Black-Karasinski interest-rate tree
Syntax
Description
[
calculates
the price for a bond option from a Black-Karasinski interest-rate
tree.Price
,PriceTree
]
= optbndbybk(BKTree
,OptSpec
,Strike
,ExerciseDates
,AmericanOpt
,CouponRate
,Settle
,Maturity
)
[
adds
optional arguments.Price
,PriceTree
]
= optbndbybk(___,Period
,Basis
,EndMonthRule
,IssueDate
,FirstCouponDate
,LastCouponDate
,StartDate
,Face
,Options
)
Examples
Price a European Call and Put Option on a Bond
Using the BK interest rate tree in the deriv.mat
file,
price a European call and put option on a 4% bond with a strike of
96. The exercise date for the option is Jan. 01, 2006. The settle
date for the bond is Jan. 01, 2005, and the maturity date is Jan.
01, 2009.
Load the file deriv.mat
, which provides BKTree
.
The BKTree
structure contains the time and forward-rate
information needed to price the bond.
load deriv.mat;
Use optbondbybk
to compute the price of the
'Call'
option.
[Price,PriceTree] = optbndbybk(BKTree,'Call',96,'01-Jan-2006',... 0,0.04,'01-Jan-2005','01-Jan-2009')
Warning: OptBonds are valued at Tree ValuationDate rather than Settle. > In optbndbytrintree (line 40) In optbndbybk (line 92) Warning: Not all cash flows are aligned with the tree. Result will be approximated. > In optbndbytrintree (line 151) In optbndbybk (line 92) Price = 0.1512 PriceTree = struct with fields: FinObj: 'BKPriceTree' PTree: {[0.1512] [0.0281 0.1481 0.3119] [0 0 0.1329 0.3886 0.3086] [0 0 0 0 0] [0 0 0 0 0]} tObs: [0 1 2 3 4] Connect: {[2] [2 3 4] [2 2 3 4 4]} Probs: {[3×1 double] [3×3 double] [3×5 double]} ExTree: {[0] [0 0 0] [0 0 1 1 1] [0 0 0 0 0] [0 0 0 0 0]}
Now use optbndbybdt
to compute the price of a
'Put'
option on the same bond.
[Price,PriceTree] = optbndbybk(BKTree,'Put',96,'01-Jan-2006',... 0,0.04,'01-Jan-2005','01-Jan-2009')
Warning: OptBonds are valued at Tree ValuationDate rather than Settle. > In optbndbytrintree (line 40) In optbndbybk (line 92) Warning: Not all cash flows are aligned with the tree. Result will be approximated. > In optbndbytrintree (line 151) In optbndbybk (line 92) Price = 0.0272 PriceTree = struct with fields: FinObj: 'BKPriceTree' PTree: {[0.0272] [0.0860 0.0204 0] [0.0474 0.1266 0 0 0] [0 0 0 0 0] [0 0 0 0 0]} tObs: [0 1 2 3 4] Connect: {[2] [2 3 4] [2 2 3 4 4]} Probs: {[3×1 double] [3×3 double] [3×5 double]} ExTree: {[0] [0 0 0] [1 1 0 0 0] [0 0 0 0 0] [0 0 0 0 0]}
The PriceTree.ExTree
output for the 'Call'
and
'Put'
option contains the exercise indicator arrays. Each element
of the cell array is an array containing 1
's where an option is
exercised and 0
's where it is not.
Input Arguments
BKTree
— Interest-rate tree structure
structure
Interest-rate tree structure, specified by using bktree
.
Data Types: struct
OptSpec
— Definition of option
character vector with value 'call'
or 'put'
| cell array of character vectors with values 'call'
or 'put'
Definition of option, specified as a NINST
-by-1
cell
array of character vectors.
Data Types: char
Strike
— Option strike price values
nonnegative integer
Option strike price value, specified as a NINST
-by-1
or NINST
-by-NSTRIKES
depending
on the type of option:
European option —
NINST
-by-1
vector of strike price values.Bermuda option —
NINST
by number of strikes (NSTRIKES
) matrix of strike price values. Each row is the schedule for one option. If an option has fewer thanNSTRIKES
exercise opportunities, the end of the row is padded withNaN
s.American option —
NINST
-by-1
vector of strike price values for each option.
Data Types: double
ExerciseDates
— Option exercise dates
serial date number | date character vector
Option exercise dates, specified as a NINST
-by-1
, NINST
-by-2
,
or NINST
-by-NSTRIKES
using serial
date numbers or date character vectors, depending on the type of option:
For a European option, use a
NINST
-by-1
vector of dates. For a European option, there is only oneExerciseDates
on the option expiry date.For a Bermuda option, use a
NINST
-by-NSTRIKES
vector of dates.For an American option, use a
NINST
-by-2
vector of exercise date boundaries. The option can be exercised on any date between or including the pair of dates on that row. If only one non-NaN
date is listed, or ifExerciseDates
is aNINST
-by-1
vector, the option can be exercised betweenValuationDate
of the stock tree and the single listedExerciseDates
.
Data Types: double
| char
AmericanOpt
— Option type
0
European/Bermuda (default) | integer with values 0
or 1
(Optional) Option type, specified as NINST
-by-1
positive
integer flags with values:
0
— European/Bermuda1
— American
Data Types: double
CouponRate
— Bond coupon rate
positive decimal value
Bond coupon rate, specified as an NINST
-by-1
decimal
annual rate or NINST
-by-1
cell
array, where each element is a NumDates
-by-2
cell
array. The first column of the NumDates
-by-2
cell
array is dates and the second column is associated rates. The date
indicates the last day that the coupon rate is valid.
Data Types: double
| cell
Settle
— Settlement date
serial date number | date character vector
Settlement date for the bond option, specified as a NINST
-by-1
vector
of serial date numbers or date character vectors.
Note
The Settle
date for every bond is set to
the ValuationDate
of the BK tree. The bond argument Settle
is
ignored.
Data Types: double
| char
Maturity
— Maturity date
serial date number | date character vector
Maturity date, specified as an NINST
-by-1
vector
of serial date numbers or date character vectors.
Data Types: double
| char
Period
— Coupons per year
2
per year (default) | vector
(Optional) Coupons per year, specified as an NINST
-by-1
vector.
Data Types: double
Basis
— Day-count basis
0
(actual/actual) (default) | integer from 0
to 13
(Optional) Day-count basis, specified as a NINST
-by-1
vector
of integers.
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
EndMonthRule
— End-of-month rule flag
1
(in effect) (default) | nonnegative integer with values 0
or 1
(Optional) End-of-month rule flag is specified as a nonnegative
integer using a NINST
-by-1
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 coupon payment date is always the same numerical day of the month.1
= Set rule on, meaning that a bond coupon payment date is always the last actual day of the month.
Data Types: double
IssueDate
— Bond issue date
serial date number | date character vector
(Optional) Bond issue date, specified as an NINST
-by-1
vector using serial date numbers or date character vectors.
Data Types: double
| char
FirstCouponDate
— Irregular first coupon date
serial date number | date character vector
(Optional) Irregular first coupon date, specified as an
NINST
-by-1
vector using serial date numbers
date or date character vectors.
When FirstCouponDate
and LastCouponDate
are
both specified, FirstCouponDate
takes precedence
in determining the coupon payment structure. If you do not specify
a FirstCouponDate
, the cash flow payment dates
are determined from other inputs.
Data Types: double
| char
LastCouponDate
— Irregular last coupon date
serial date number | date character vector
(Optional) Irregular last coupon date, specified as a
NINST
-by-1
vector using serial date numbers or
date character vectors.
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. If you
do not specify a LastCouponDate
, the cash flow
payment dates are determined from other inputs.
Data Types: char
| double
StartDate
— Forward starting date of payments
serial date number | date character vector
(Optional) Forward starting date of payments (the date from
which a bond cash flow is considered), specified as a NINST
-by-1
vector
using serial date numbers or date character vectors.
If you do not specify StartDate
, the effective
start date is the Settle
date.
Data Types: char
| double
Face
— Face value
100
(default) | nonnegative value | cell array of nonnegative values
(Optional) Face or par value, specified as anNINST
-by-1
vector.
Data Types: double
Options
— Derivatives pricing options
structure
(Optional) Derivatives pricing options, specified as structure
that is created with derivset
.
Data Types: struct
Output Arguments
Price
— Expected prices of bond option at time 0
matrix
Expected price of the bond option at time 0
,
returned as a NINST
-by-1
matrix.
PriceTree
— Structure containing trees of vectors of instrument prices and accrued interest for each node
structure
Structure containing trees of vectors of instrument prices and accrued interest, and a vector of observation times for each node. Values are:
PriceTree.PTree
contains the clean prices.PriceTree.tObs
contains the observation times.PriceTree.Connect
contains the connectivity vectors. Each element in the cell array describes how nodes in that level connect to the next. For a given tree level, there areNumNodes
elements in the vector, and they contain the index of the node at the next level that the middle branch connects to. Subtracting 1 from that value indicates where the up-branch connects to, and adding 1 indicated where the down branch connects to.PriceTree.Probs
contains the probability arrays. Each element of the cell array contains the up, middle, and down transition probabilities for each node of the level.PriceTree.ExTree
contains the exercise indicator arrays. Each element of the cell array is an array containing1
's where an option is exercised and0
's where it isn't.
More About
Bond Option
A bond option gives the holder the right to sell a bond back to the issuer (put) or to redeem a bond from its current owner (call) at a specific price and on a specific date.
Financial Instruments Toolbox™ supports three types of put and call options on bonds:
American option: An option that you exercise any time until its expiration date.
European option: An option that you exercise only on its expiration date.
Bermuda option: A Bermuda option resembles a hybrid of American and European options. You can exercise it on predetermined dates only, usually monthly.
For more information, see Bond Options.
Version History
MATLAB コマンド
次の MATLAB コマンドに対応するリンクがクリックされました。
コマンドを MATLAB コマンド ウィンドウに入力して実行してください。Web ブラウザーは MATLAB コマンドをサポートしていません。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)