Closed sdwfrost closed 3 years ago
Hi @sdwfrost, having r
as an Int
definitely helps for computing the normalization constant, but other than that there is no constraint. Having another GP
as a source for r
would be extremely complex I think... Since r
appears in the binomial coefficient my wild guess would be that gradients would be quite unstable.
Nonetheless I can make a PR to change that, I am in the AISTATS deadline rush right now but I will take care of it afterwards (with a partial refactoring of the package actually :P )
Hi @sdwfrost, so I had a look if r
could be unrestricted to Integers and the problem would come from this line : https://github.com/theogf/AugmentedGaussianProcesses.jl/blob/089025c850fb4e0c3ff29cbf0a5ede339d4894e0/src/likelihood/negativebinomial.jl#L131
The binomial can only take integers, if you have a an alternative solution, I would be happy to add it!
You can use Gamma functions instead of binomial coefficients, as described here. Ideally, I'd like a parameterization along the same lines as the alternative parameterization in Stan.
Ok so I created #68, I did not copy the Stan parametrization as it would become too heavy, but it is now possible to use Real numbers for r
. I also added a small example for it in docs/examples
Hi @theogf! I'd like to fit some overdispersed count data, for which I'd like to use a negative binomial distribution, and infer the overdispersion parameter (ideally also putting a GP on that as well but that's another issue). I saw that in your implementation of the negative binomial, you have
r
as anInt
rather than allowing it to be aFloat
. Is there any reason to restrictr
in this way?