[R-SIG-Finance] euro call by integration

Kris kk2250 at optonline.net
Sat Apr 13 18:49:29 CEST 2013


You need to integrate payoff x density

[disc factor x pmax(s-k,0) x density ]
below

Also  the std error of the integration unlikely it is going to be that big but worth keeping in mind.



On Apr 13, 2013, at 7:42 AM, Enrico Schumann <es at enricoschumann.net> wrote:

> On Sat, 13 Apr 2013, Dominykas Grigonis <dominykasgrigonis at gmail.com> writes:
> 
>> Valuing european call option by taking expectation and integrating:
>> 
>> gmb <- function(x,s0=100,r=0.05,vol=0.1){
>> s0*exp( (r - vol^2/2) + vol * x)}
>> 
>> fun <- function(x, K=100){
>> (gbm(x) - 100) * dnorm(x)}
>> 
>> min = -(log(1) + (0.05-0.1^2/2)) / 0.1
>> integrate(fun,min,Inf)
>> 
>> could someone tell me what am I doing wrong? I do not even know if this is R related question or not... 
>> 
>> returns 7.153855, while actual risk neutral price is 6.804958
>> 
>> Thank you in advance.
>> 
>> Kind regards,-- 
>> Dominykas Grigonis
> 
> I did not run your code, but shouldn't you discount the result?
> 
> 
> 
> -- 
> Enrico Schumann
> Lucerne, Switzerland
> http://enricoschumann.net
> 
> _______________________________________________
> R-SIG-Finance at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-finance
> -- Subscriber-posting only. If you want to post, subscribe first.
> -- Also note that this is not the r-help list where general R questions should go.



More information about the R-SIG-Finance mailing list