Serving the Quantitative Finance Community

 
User avatar
ksmchan
Topic Author
Posts: 0
Joined: May 18th, 2011, 2:40 pm

Hull White in Quantlib (build tree)

July 22nd, 2015, 3:00 am

Hi all,How can I use Quantlib to print out each tree node value and probability for my Hull White trinomial tree? Thanks.Kevin
 
User avatar
ksmchan
Topic Author
Posts: 0
Joined: May 18th, 2011, 2:40 pm

Hull White in Quantlib (build tree)

July 22nd, 2015, 3:08 am

The following is my HullWhite definition:TimeGrid grid(times.begin(), times.end(), 30);boost::shared_ptr<HullWhite> modelHW(new HullWhite(yieldCurve));Thanks for help
 
User avatar
ksmchan
Topic Author
Posts: 0
Joined: May 18th, 2011, 2:40 pm

Hull White in Quantlib (build tree)

July 22nd, 2015, 8:18 am

I tried to write the following, but seems fail, any idea? ThanksTrinomialTree hwTree = modelHW->tree;cout << hwTree.size(0);Kevin