Skip to content

GBSVolatility not working on vectors?

3 messages · Shivam, Joachim Breit

#
Hi Joachim,

Somehow I am not able to replicate your data in my workspace. But I
would like to suggest you to try the below:
S = dtemp$c , X = dtemp$strike, Time = dtemp$ntd / 253.8,
r = pmax(dtemp$rb, 0), b = pmax(dtemp$rb, 0))

Hope it helps.

Regards,
Shivam
#
Cool, that works.
I'm a beginner (since a decade or so :-)
Did not know Vectorize()

Thank you so much!

Am 25.09.2014 14:17, schrieb Shivam:
#
Rejoiced too soon.

It worked with my mini-dataframe but when doing it with the big one I got:

Fehler in uniroot(.fGBSVolatility, interval = c(-10, 10), price = price,  :
   f() values at end points not of opposite sign



Am 25.09.2014 14:32, schrieb Joachim Breit: