I was hoping to include a Poisson variable as intermediate parameter in my model, though I know Stan doesn’t allow integer parameters. I was wondering if log_sum_exp or similar functions can be applied on Poisson…
The math expression of this part of model is: \lambda_t \sim \Gamma(\alpha, 1); N_t |\lambda_t \sim Poisson(\lambda_t\frac{1-\rho}{\rho}); \zeta_t|N_t \sim \Gamma(N_t, \beta/\rho)
This is a time series model, with X_t be observations and model as X_t = \rho X_{t-1} + \zeta_t. If the integer parameter is supported, I was hoping some model looks like:
corresponds to the N>0 part of the marginalization. Poisson distribution has non-negligible chance of producing a zero; gamma(0,beta) is a degenerate always-zero distribution that needs to be considered separately.
Thanks @maxbiostat! Sorry about the late response…my PC was sent for repair so I can’t check the forum quite easily…
I never thought about Bessel function, it looks like a perfect closed form solution. I’ll try coding as soon as my computer comes back. Thanks again for the help!
To anyone reading this post in the future, I think one way to handle this complication cleanly is to truncate the distribution of N_t at zero and then the expression becomes