My question is similar to this one.
Assume we have a distribution from which we can only sample, but have no information on its pmf and consider further some count data:
library("GillespieSSA")
sampleFromDist <- function(param){
out <- ssa(x0=c(X=1000),a=c("c*X"),nu=matrix(-1),parms=c(c=param),tf=1)$data
return(out[length(out)])
}
data <- c(0,0,1,1,1,1,1,1,1,1,1,2,2,2,2,3,3,3,4,4,5,7,33,37,100)
How can a discrete distribution form which we can only sample be fitted to the data?
One standard approach could be to sample very often for a given parameter to compute the likelihood and then maximize it. However, since the data is heavily tailed, sampling very often until each value in the data is observed is computationally infeasible.
Note: I know that for the given example, one can actually derive a closed form expression for the pmf. The actual GillespieSSA I need to fit is more complicated and also has more parameters.