I need to know if the dispersion estimate showed in the output of the of genmode procedure for the negative binomial dist is an estimation made before making the estimation of the general linear model predictor coefficients.
Not sure if this is the answer, but in the Details section of the documentation, in the Dispersion Parameter section, the final sentence is:
In the case of the negative binomial distribution, PROC GENMOD reports the “dispersion” parameter estimated by maximum likelihood. This is the negative binomial parameter k defined in the section Response Probability Distributions.
To me this would indicate that the dispersion estimate is not made before the estimation, but is "simultaneously" estimated.
Steve Denham
Thank you for your answer, but I’ve read that documentation as well as other documentations about genmode proc. In one of them says “The methodology of generalized linear models (GLMs) requires that estimation be in terms of µ; Le. in the case of the negative binomial k is placed into the variance and deviance function as a known constant as µ varies.” I want to know if one do not specify the constant for k, SAS estimates it using MLE by default, in order to begin the MLE of the linear model, so its like solving a problem of estimating the distribution parameter (the parameter r -> k=1/r) of the neg binomial using MLE without considering or using the GLM.
Here's my feeling: It is included as yet another parameter in the likelihood function, with an initial value from a weighted least squares estimate, the same as any of the other parameters.
For an example, using the Poisson regression example in the Getting Started section, and changing the code slightly:
proc genmod data=insure;
class car age;
model c = car age / dist = negbin
link = log
offset = ln
itprint;
run;
Hopefully, this answer makes some sense.
Steve Denham
This will give the value of the parameters at each step in the iteration in the output.
Ok but I need to estimate the parameters for negative binomial distribution (pdf) using maximun likelihood, then estimate the parameter for the Poisson by ML, which can be done by hand, but later I need to conduct a likelihood ratio test between these two distributions. The problem is that, I have SAS Base 9.1 and SAS Stat, all the procedures I found were made to work with regression models. Do you know if there's a way to conduct this distributional analysis. Thanks a lot.
This one I do have some ideas about. From each run, you will get a table of information criteria, giving things like Akaike's Information Criteria, etc. Now a likelihood ratio test looking at change in -2 log likelihood is possible, BUT since the models are not nested, getting the proper degrees of freedom is difficult, and really, I don't know that the difference will even be distributed as chi-squared. However, if the fixed effects are identical in the two models, a direct comparison of the various IC results can indicate which distribution better fits your data. SAS uses the smaller is better criterion. If there is a decided advantage to one of the distributions, then I would proceed with using it for subsequent analysis.
I hope this helps.
Steve Denham
So basically I can run the model with a response variable (the one I'm analyzing) and no predictors, use the information displayed in the "Analysis Of Maximum Likelihood Parameter Estimates" table to calculate the MLE of the distribution parameters and then use the Akaike's Information Criteria to evaluate which model better fits the data. Am I right? Once again, thank you very very much.
This is close. I would include the predictors, as the dispersion parameter for the negative binomial is going to be data dependent.
Steve Denham
The thing is that I want to fit the parameters to a single data set. I found a way to do this using SAS IML but I only have SAS Base 9.1 and SAS Stat
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.