金融仿真笔记(7)

1.fixedbyzero 用零息债券的即期利率给固定票据定价,Price = fixedbyzero(RateSpec, CouponRate, Settle, Maturity)。相应的也有floatbyzero,浮动利率票据 。但是这里的参数就不同了,  Price = floatbyzero(RateSpec, Spread, Settle, Maturity),spread表示在零息债券年化收益上方多少个基点。

2.swapbyzero 给互换定价,[Price, SwapRate] = swapbyzero(RateSpec, LegRate, Settle, Maturity),LegRate是一个N*2的矩阵,形式是[CouponRate Spread] or [Spread CouponRate],第一列表示收入,第二列表示支出,swapRate当互换价格为零时,需要设定的固定的利率。

3.以上的所有函数有一个通式:intenvprice和intenvsens.Computes prices for instruments against a set of zero coupon bond rate curve(s). INTENVPRICE handles the following instrument types: 'Bond', 'CashFlow','Fixed', 'Float', 'Swap'.  Type "help instadd" to construct defined types。
函数语法Price = intenvprice(RateSpec, InstSet)。inSet里面不同的类型有不同的数据域,是在这里面对证券类型进行分类了吧。
intenvsens是对价格进行敏感度分析的东西,语法是[Delta, Gamma, Price] = intenvsens(RateSpec, InstSet)。

This entry was posted in 读书笔记 and tagged . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *