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:
> dtemp$iva <- Vectorize(GBSVolatility)(price = dtemp$ask, TypeFlag = dtemp$cp, 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 -- *Victoria Concordia Crescit* _______________________________________________ R-SIG-Finance@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.