找回密码
 注册
查看: 403|回复: 0

R语言 RQuantLib包 EuropeanOptionArrays()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-9-28 20:33:00 | 显示全部楼层 |阅读模式
EuropeanOptionArrays(RQuantLib)
EuropeanOptionArrays()所属R语言包:RQuantLib

                                        European Option evaluation using Closed-Form solution
                                         采用封闭形式的解决方案的欧式期权评估

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

The EuropeanOptionArrays function allows any two of the numerical input parameters to be a vector, and a list of matrices is returned for the option value as well as each of the 'greeks'. For each of the returned matrices, each element  corresponds to an evaluation under the given set of parameters.
功能允许EuropeanOptionArrays的任意两个数字输入参数是一个向量,返回矩阵的选项值的列表以及每个“希腊人”。对于每一个返回的矩阵,每一个元素对应的评价,根据给定的一组参数。


用法----------Usage----------


EuropeanOptionArrays(type, underlying, strike, dividendYield, riskFreeRate, maturity, volatility)
oldEuropeanOptionArrays(type, underlying, strike, dividendYield, riskFreeRate, maturity, volatility)
plotOptionSurface(EOres, ylabel="", xlabel="", zlabel="", fov=60)



参数----------Arguments----------

参数:type
A string with one of the values call or put
一个字符串一个的值call或put的


参数:underlying
(Scalar or list) current price(s) of the underlying stock
(标量或列表)标的股票的当前价格(S)


参数:strike
(Scalar or list) strike price(s) of the option
(标量或列表)行使价(S)的选项


参数:dividendYield
(Scalar or list) continuous dividend yield(s) (as a fraction) of the stock
(标量或列表)连续的股息收益率的股票(S)(一小部分)


参数:riskFreeRate
(Scalar or list) risk-free rate(s)
(标量或列表)无风险利率(S)


参数:maturity
(Scalar or list) time(s) to maturity (in fractional years)
(标量或列表)至到期日时间(s)(在分数几年)


参数:volatility
(Scalar or list) volatilit(y|ies) of the underlying stock
(标量或列表)的标的股票volatilit(Y | IES)


参数:EOres
result matrix produced by EuropeanOptionArrays
结果矩阵生产的EuropeanOptionArrays


参数:ylabel
label for y-axsis
标签Y-axsis


参数:xlabel
label for x-axsis
对于x-axsis标签


参数:zlabel
label for z-axsis
标签Z-axsis的


参数:fov
viewpoint for 3d rendering
3D渲染的观点


Details

详细信息----------Details----------

The well-known closed-form solution derived by Black, Scholes and Merton is used for valuation.
著名的黑色,Scholes和Merton得到封闭形式的解决方案进行估值。

Please see any decent Finance textbook for background reading, and the QuantLib documentation for details on the QuantLib implementation.  
请参阅任何像样的金融教科书的背景阅读,QuantLibQuantLib实施的细节上的文件。


值----------Value----------

The EuropeanOptionArrays function allows any two of the numerical input parameters to be a vector or sequence. A list of two-dimensional matrices is returned. Each cell corresponds to an evaluation under the given set of parameters.
EuropeanOptionArrays函数允许的数值的任何两个输入参数是一个向量或序列。二维矩阵的列表被返回。每个单元格对应的评价,根据给定的一组参数。

For these functions, the following components are returned: <table summary="R valueblock"> <tr valign="top"><td>value</td> <td> (matrix) value of option</td></tr> <tr valign="top"><td>delta</td> <td> (matrix) change in value for a change in the underlying</td></tr> <tr valign="top"><td>gamma</td> <td> (matrix) change in value for a change in delta</td></tr> <tr valign="top"><td>vega</td> <td> (matrix) change in value for a change in the underlying's volatility</td></tr> <tr valign="top"><td>theta</td> <td> (matrix) change in value for a change in delta</td></tr> <tr valign="top"><td>rho</td> <td> (matrix) change in value for a change in time to maturity</td></tr> <tr valign="top"><td>dividendRho</td> <td> (matrix) change in value for a change in delta</td></tr> <tr valign="top"><td>parameters</td> <td> List with parameters with which object was created</td></tr>
对于这些函数,返回以下组件:<table summary="R valueblock"> <tr valign="top"> <TD>value </ TD> <TD>(矩阵)值的选项</ TD> </ TR> <tr valign="top"> <TD> delta </ TD> <TD>(矩阵)的变化值的变化的基础</ TD> </ TR> < TR VALIGN =“顶”> <TD> gamma </ TD> <TD>(矩阵)的变化值的变化Delta</ TD> </ TR> <tr valign="top"> < TD>vega</ TD> <TD>(矩阵)值的变化底层的波动性变化</ TD> </ TR> <tr valign="top"> <TD>theta </ TD> <TD>(矩阵)的变化值的变化Delta</ TD> </ TR> <tr valign="top"> <TD> rho</ TD> <TD> (矩阵)的到期时间的变化值变化</ TD> </ TR> <tr valign="top"> <TD>dividendRho </ TD> <TD>(矩阵)价值变动改变Delta</ TD> </ TR> <tr valign="top"> <TD>parameters </ TD> <TD>对象被创建的参数列表</ TD> </ TR>

</table> The oldEuropeanOptionArrays function is an older implementation which vectorises this at the R level instead but allows more general multidimensional arrays.
</ TABLE> oldEuropeanOptionArrays函数是一个较旧的的实施vectorises这在R级,而不是,但允许更一般的多维数组。


注意----------Note----------

The interface might change in future release as QuantLib
该接口在将来的版本中可能会改变QuantLib


(作者)----------Author(s)----------


Dirk Eddelbuettel <a href="mailto:edd@debian.org">edd@debian.org</a> for the <font face="Courier New,Courier" color="#666666"><b>R</b></font> interface;
the QuantLib Group for <code>QuantLib</code>



参考文献----------References----------

<h3>See Also</h3>

实例----------Examples----------


# define two vectos for the underlying and the volatility[定义了两个vectos的根本原因和波动性]
und.seq <- seq(10,180,by=2)
vol.seq <- seq(0.1,0.9,by=0.1)
# evaluate them along with three scalar parameters[,评估他们一起三个标量参数]
EOarr <- EuropeanOptionArrays("call", underlying=und.seq,
                              strike=100, dividendYield=0.01,
                              riskFreeRate=0.03,
                              maturity=1, volatility=vol.seq)
# and look at four of the result arrays: value, delta, gamma, vega[看的结果数组中的四个值,冲值,伽玛系数维加]
old.par <- par(no.readonly = TRUE)
par(mfrow=c(2,2),oma=c(5,0,0,0),mar=c(2,2,2,1))
plot(EOarr$parameters.underlying, EOarr$value[,1], type='n',
     main="option value", xlab="", ylab="")
topocol <- topo.colors(length(vol.seq))
for (i in 1:length(vol.seq))
  lines(EOarr$parameters.underlying, EOarr$value[,i], col=topocol[i])
plot(EOarr$parameters.underlying, EOarr$delta[,1],type='n',
     main="option delta", xlab="", ylab="")
for (i in 1:length(vol.seq))
  lines(EOarr$parameters.underlying, EOarr$delta[,i], col=topocol[i])
plot(EOarr$parameters.underlying, EOarr$gamma[,1],type='n',
     main="option gamma", xlab="", ylab="")
for (i in 1:length(vol.seq))
  lines(EOarr$parameters.underlying, EOarr$gamma[,i], col=topocol[i])
plot(EOarr$parameters.underlying, EOarr$vega[,1],type='n',
     main="option vega", xlab="", ylab="")
for (i in 1:length(vol.seq))
  lines(EOarr$parameters.underlying, EOarr$vega[,i], col=topocol[i])
mtext(text=paste("Strike is 100, maturity 1 year, riskless rate 0.03",
        "\nUnderlying price from", und.seq[1],"to", und.seq[length(und.seq)],
        "\nVolatility  from",vol.seq[1], "to",vol.seq[length(vol.seq)]),
      side=1,font=1,outer=TRUE,line=3)
par(old.par)

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2024-11-26 20:26 , Processed in 0.025237 second(s), 15 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表