I'm modeling the number of doctor visits (a count variable) on factors such as income, chronic condition, insurance, etc. I use the canned Stata command poisson y x1 x2, etc. but I am encountering the following issue when trying to find the sample average of the residuals:
Stata does not allow me to execute predict resids, residuals after I've ran the poisson regression above.. I then tried to generate the residuals using the formula "y-yhat", yet I get a sample average of residuals with a negative average mean (-6.96e-09...) - is this 2nd approach even correct ? Also, I tried fitting the model with glm, f(poisson)and then running
Any thoughts here?
predict resids, residuals ,but Stata only allowed me to run it as "predict resids" and automatically added " (option mu assumed; predicted mean docvis)" and as a result the sample average of residuals with this approach is a constant value of 3.81 throughout all observations!
Any thoughts here?
Comment