modified to use own poisson distribution