I am confused about the graphs in Gamma Distribution documentation page: http://www.boost.org/doc/libs/1_39_0/libs/math/doc/sf_and_dist/html/math_too...
The first (blue) curve in the first graph suggests that Gamma PDF(0.0, 0.5, 1.0) == 1.0. Is this correct? Shouldn't it go to infinity as x approaches 0?
It does: the graph is generated automagically, and it just so happens that for that choice of parameters the smallest value sampled is 0.94 giving a misleading looking graph, I'll try and tweak things so it's clear that the curve goes to infinity for shape < 1.
PDF(x, k, theta) = x^(k-1)*exp(-x/theta)/(theta^k*gamma(k)) PDF(0.0, 0.5, 1.0) = 0^(-0.5)*1/gamma(0.5) = 1/(0^0.5 * gamma(0.5)) = Inf
In the second graph both first and third curves have scale = 2 and shape = 2, yet they look different.
Ooops, the labels are wrong: should be scale = 0.5, 1 and 2, will fix in SVN shortly. Apologies for the confusion, and thanks for the feedback! John.