Given likelihood of gamma (external approximation convoluted gamma) calculate likelihood of NB

I found a function that approximates efficiently the density of a convoluted gamma

gamma(a1, b1) + gamma(a2, b2) + ...
  PACKAGE = "coga", 
  c(1, 3, 5, 2, 2), 
  c(3, 5, 3, 5, 3)
[1] 0.003897655

Now is it possible to algebrically calulate the likelihood of a negative binomial from that?

I guess the explicit formulation would be

y ~ poisson(mu)
mu ~ R_convoluted_gamma(alpha1, alpha2, alpha3, beta1, beta2, beta3);

But I would like to avoid the creation of an intermediate parameter mu.


The sum of independend gamma distributions leads to a nested integral expression, but maybe the approximiation can bring you closer.

1 Like

I played a little bit with the difference of gamma distributions.

The saddle approximation has an analytical solution for the convolution of two gammas.