[R] Help required: binomial option pricing using package

sonal sonal.sarkar at arxaa.com
Fri Dec 24 05:51:50 CET 2010

I'm using the CRRBinomialTreeOption function (in package "fOptions") with a
loop for pricing a large number of options. But I can't transfer the values
obtained from this function to a "numeric" matrix as the outcome of this
function is not a simple numeric.

The following is the piece of code:

for(j in 1:9){for(i in 1:250)                                                                                                          

R output:
Error in option.price[i, j] = CRRBinomialTreeOption(TypeFlag = "ca", S =
data[(i +  : 
  object of type 'S4' is not subsettable

I'm very new to R and can't find a solution with my knowledge at this
moment. Plz help.

View this message in context: http://r.789695.n4.nabble.com/Help-required-binomial-option-pricing-using-package-tp3162935p3162935.html
Sent from the R help mailing list archive at Nabble.com.

More information about the R-help mailing list