Posted by
Joseph Wang-2 on
Mar 08, 2007; 5:20pm
URL: http://quantlib.414.s1.nabble.com/New-Basket-Option-Code-and-question-about-StochasticProcessArray-tp9247.html
Thanks to everyone that sent me code and pointers.
I did a backward compatible refactoring of the basket option code that makes
it relatively easy to add new types of basket options. Instead of using a
enum to define the basket option, the code now allows you to subclass
BasketOptionType which contains code on how to calculate the price of that
option. There are now AverageBasketOptionType, MinBasketOptionType, and
MaxBasketOptionType, and by moving the option calculation code out of the
engines, any new basket options can be calculated automatically by the monte
carlo code.
I'm now in the process of putting together some swig wrappers for all of this.
I do have a question about StochasticProcessArray. Right now you have to
define a vector of StochasticProcesses and then put that into the constructor
of the array. Would it be better to add a "push_back" method to the
StochasticProcessArray so that you create an array object and then insert
processes to it?
--
-------------------------------------------------------------------------------
Joseph Wang Ph.D. -
[hidden email]
China Derivatives Researcher and Software Developer - QuantLib
http://en.wikiversity.org/wiki/User:Roadrunner-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev