楼主: DanL
2828 3

SAS期权定价 程序求助 [推广有奖]

  • 1关注
  • 1粉丝

硕士生

20%

还不是VIP/贵宾

-

威望
0
论坛币
122 个
通用积分
2.8500
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
32343 点
帖子
127
精华
0
在线时间
156 小时
注册时间
2013-1-9
最后登录
2023-1-30

楼主
DanL 发表于 2013-6-13 11:10:10 |AI写论文
5论坛币
以下是B-S模型的程序 ,想要给r s t 这些变量定个数 比如r=0.05 该怎么写?程序的开头怎么写?

start price_c (r,sigma,t,s,x);
d1=(log(s/x)+(r+sigma##2/2)*t)/(sigma*sqrt(t));
d2=d1-sigma*sqrt(t);
c=s*cdf('normal',d1)-x*exp(-r*t)*cdf('normal',d2);
return(c);
finish price_c;
print c;

最佳答案

邓贵大 查看完整内容

where r=risk-free interest rate, sigma=implied volatility, t = time to expiration in years, s=current price, x = strike price.
关键词:期权定价 normal finish RETURN Sigma 程序

沙发
邓贵大 发表于 2013-6-13 11:10:11
  1. proc iml;
  2. start price_c (r,sigma,t,s,x);
  3. d1=(log(s/x)+(r+sigma##2/2)*t)/(sigma*sqrt(t));
  4. d2=d1-sigma*sqrt(t);
  5. c=s*cdf('normal',d1)-x*exp(-r*t)*cdf('normal',d2);
  6. return(c);
  7. finish price_c;
  8. c = price_c(.05, .3, 1/12, 100, 120);
  9. print c;
  10. quit;
复制代码
where r=risk-free interest rate, sigma=implied volatility, t = time to expiration in years, s=current price, x = strike price.
Be still, my soul: the hour is hastening on
When we shall be forever with the Lord.
When disappointment, grief and fear are gone,
Sorrow forgot, love's purest joys restored.

藤椅
respringwa 发表于 2013-6-13 18:14:00
顶个

板凳
DanL 发表于 2013-6-17 07:59:44
现在急需要这个啊,换个问题:怎么用SAS调用这个程序啊?说得具体点!!!急需!!!

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

本版微信群
加好友,备注cda
拉您进交流群
GMT+8, 2026-1-9 04:29