cap
Price caps using Normal or Bachelier pricing model
句法
Description
Examples
使用盖子使用正常模型for Negative Rates
考虑一个投资者,该投资者签订了一份合同,该合同将100,000美元贷款的利率限制为季度的季度复合3个月,从2009年1月1日开始。复合和波动率为20%,使用此数据计算上限价格。首先,计算r一个teSpec
,然后使用cap
计算卡普里斯
。
估值日期='Jan-01-2008';EndDates ='April-01-2010';r一个tes = 0.0069394; Compounding = -1; Basis = 1; RateSpec = intenvset(“评估日期”,评估日期,...“开始日”,评估日期,'EndDates',终点,...'Rates',,,,r一个tes,'Compounding',,,,Compounding,'Basis', 基础);定居='Jan-01-2009';百分比从一年开始成熟度=“ 2009年4月1日”;波动率= 0.20;caprate = -0.008;capReset = 4;校长= 100000;capprice = capbynormal(Ratesspec,Caprate,setter,Ederity,Everations,lopatition ,,...'Reset',,,,C一个preset,“评估日期”,评估日期,'主要的',,,,Principal,...'Basis',,,,Basis)
卡普里斯= 2.1682e+03
使用盖子使用cap
并比较Capbyblk
Define ther一个teSpec
。
settle = datenum('20 -Jan-2016');ZeroTimes = [.5 1 2 3 4 5 7 10 20 30]'; ZeroRates = [0.0052 0.0055 0.0061 0.0073 0.0094 0.0119 0.0168 0.0222 0.0293 0.0307]'; ZeroDates = datemnth(Settle,12*ZeroTimes); RateSpec = intenvset('开始日期',定居,'EndDates',,,,ZeroDates,'Rates',Zerorates)
Ratespec =结构with fields:FinObj: 'RateSpec' Compounding: 2 Disc: [10x1 double] Rates: [10x1 double] EndTimes: [10x1 double] StartTimes: [10x1 double] EndDates: [10x1 double] StartDates: 736349 ValuationDate: 736349 Basis: 0 EndMonthRule: 1
定义帽仪器和价格Capbyblk
。
锻炼= datenum('20-Jan-2026');[[~,ParSwapRate] = swapbyzero(RateSpec,[NaN 0],Settle,ExerciseDate)
parswaprate = 0.0216
罢工= .01;blackvol = .3;stransvol = blackvol*parswaprate;价格= capbyblk(Ratesspec,罢工,定居,锻炼,blackvol)
价格= 11.8693
使用帽仪器使用cap
。
Price_Normal = capbynormal(RateSpec,Strike,Settle,ExerciseDate,NormalVol)
Price_normal = 12.5495
使用帽仪器使用cap
负面打击。
PRICE_Normal = capbynormal(Ratesspec, - 。005,定居点,锻炼,常规)
Price_Normal = 24.4816
输入参数
Strike
-行使帽的比率
小数
行使上限的比率,指定为NINST
-by-1
向量of decimal values.
数据类型:double
定居
-定居ment date for cap
serial date number|date character vector|DateTime对象|字符串对象
CAP的结算日期,指定为NINST
-by-1
串行日期数,日期字符向量,日期对象或字符串对象的向量。
数据类型:double
|char
|datetime
|细绳
Maturity
-Maturity date for cap
serial date number|date character vector|DateTime对象|字符串对象
Maturity date for the cap, specified as aNINST
-by-1
串行日期数,日期字符向量,日期对象或字符串对象的向量。
数据类型:double
|char
|datetime
|细绳
挥发性
-正常波动值
n你meric
正常波动值,,,,specified as aNINST
-by-1
向量of numeric values.
For more information on the Normal model, see使用功能处理负利率负利率。
数据类型:double
名称值参数
指定可选的逗号分隔对名称,价值
一个rguments.姓名
是参数名称和Value
is the corresponding value.姓名
must appear inside quotes. You can specify several name and value pair arguments in any order as姓名1,,,,Value1,...,NameN,ValueN
。
[capprice,caplets] = capbynormal(Ratesspec,罢工,定居点,成熟度,波动性,“重置”,capreset,'principtal',100000,“基础”,7)
reset
-reset frequency payment per year
1
(默认)|n你meric
每年重置频率付款,指定为逗号分隔对'Reset'
一个nd aNINST
-by-1
向量。
数据类型:double
Principal
-名义本金
100
(默认)|n你meric
名义本金金额,指定为逗号分隔对'主要的'
一个nd aNINST
-by-1
of notional principal amounts, or aNINST
-by-1
单元阵列。每个元素NINST
-by-1
单元阵列是一个NumDates
-by-2
单元阵列,第一列是日期,第二列是相关的主量。日期表示主值有效的最后一天。
UsePrincipal
至p一个ss a schedule to compute the price for an amortizing cap.
数据类型:double
|cell
Basis
-Day-count basis of instrument
0
((一个ctual/actual)(默认)|整数来自0
至13
Day-count basis of instrument representing the basis used when annualizing the input forward rate, specified as the comma-separated pair consisting of'Basis'
一个nd aNINST
-by-1
向量of integers. Values are:
0 =实际/实际/实际
1 = 30/360(SIA)
2= actual/360
3 =实际/365
4 = 30/360 (PSA)
5 = 30/360(ISDA)
6 = 30/360(欧洲)
7 =实际/365(日语)
8 =实际/实际(ICMA)
9 = actual/360 (ICMA)
10 =实际/365(ICMA)
11= 30/360E (ICMA)
12 =实际/365(ISDA)
13= BUS/252
For more information, seeBasis。
数据类型:double
ValuationDate
-观察日期
如果ValuationDate
未指定,然后定居
用来(默认)|serial date number|date character vector|DateTime对象|字符串对象
Observation date of the investment horizon, specified as the comma-separated pair consisting of“评估日期”
一个nd a serial date number, date character vector, datetime object, or string array.
数据类型:double
|char
|datetime
|细绳
ProjectionCurve
-r一个tecurve used in generating future cash flows
如果ProjectionCurve
未指定,然后r一个teSpec
用来both for discounting cash flows and projecting future cash flows(默认)|结构你re
用于投影未来现金流的利率曲线,指定为逗号分隔的一对“投影”
一个nd rate curve structure. This structure must be created usingIntenVSet
。Use this optional input if the forward curve is different from the discount curve.
数据类型:结构
输出参数
卡普里斯
- 帽子的预期价格
向量
Expected price of the cap, returned as aNINST
-by-1
向量。
帽子
-帽子
一个rr一个y
帽子,返回NINST
-by-NCF
一个rr一个y of caplets, padded with南
s。
更多关于
C一个p
一个capis a contract that includes a guarantee that sets the maximum interest rate to be paid by the holder, based on an otherwise floating interest rate.
The payoff for a cap is:
For more information, seeC一个p。
也可以看看
matlabコマンド
Matlabコマンドコマンドにするがクリックされまし。。
コマンドをMATLABコマンドウィンドウに入力して実行してください。Webブラウザーは马TLAB コマンドをサポートしていません。
Select a Web Site
选择一个网站以获取可用的翻译内容,并查看本地事件和优惠。根据您的位置,我们建议您选择:。
You can also select a web site from the following list:
如何获得最佳网站性能
选择中国网站(中文或英语)以获得最佳场地性能。其他Mathworks乡村网站未针对您所在的访问进行优化。
一个mericas
- 一个mérica Latina((Español)
- C一个n一个da((English)
- United States((English)