pdat = data.frame(y = rgamma(10, shape=exp(-1))) # Not good data!
os = 2
fit = vglm(y ~ 1, poissonp(os, 2), pdat, tra=TRUE, crit="c")
fit = vglm(y ~ 1, poissonp(os, 3), pdat, tra=TRUE, crit="c") # Slow convergence?
fit = vglm(y ~ 1, poissonp(os, 3, idensi=1), pdat, trace=TRUE, crit="c")
head(fitted(fit))
with(pdat, mean(y))
coef(fit, matrix = TRUE)
Coef(fit)
Run the code above in your browser using DataLab