I am trying to convert a matlab code to R. Most of the conversion statements are simple, but problem is with return.
Since it's a recursive function it's a bit complicated. Anyway in matlab we can have return statment like [price, notional] = functionname() and also for the same function... notional(1) = functionname() how to do this in R? i have tried using data frame but still getting errors! Yes the functioname() function is recursive...but am guessing it shouldn't matter. also there is no "return" statement in MatLab.......so finding it a bit confusing. ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.