From: Peter C. <pca...@gm...> - 2013-02-07 18:53:10
|
Hi, there is an implementation of the gamma function and the incomplete gamma function in ql (be careful, "incomplete gamma function" seems to be defined differently at different places confusingly). With these it is easy to compute your pdf and cdf. The inverse cdf seems not to be available in ql. I implemented it using a numerical zero search. I am not sure if there are better ways to do this ? Peter Am 07.02.2013 14:52, schrieb Grześ Andruszkiewicz: > Hi, > > Is the generation of gamma distributed random variables implemented in > QuantLib (e.g. the inverse cumulative function)? There is a > GammaDistribution class, but it might be only density... > > I can always use boost if the answer is negative. > > Cheers, > Grzegorz > > ------------------------------------------------------------------------------ > Free Next-Gen Firewall Hardware Offer > Buy your Sophos next-gen firewall before the end March 2013 > and get the hardware for free! Learn more. > http://p.sf.net/sfu/sophos-d2d-feb > _______________________________________________ > QuantLib-dev mailing list > Qua...@li... > https://lists.sourceforge.net/lists/listinfo/quantlib-dev |