## proc genmod graphics for count data model fit assessment

Solved
Occasional Contributor
Posts: 6

# proc genmod graphics for count data model fit assessment

[ Edited ]

Hello,

I am a beginner stat student. I am trying to plot observed and predicted Poisson and negative binomial probabilities against the

data observed. I have no experience or prior knowledge of graphing. I am getting lost in all complex explanations.

Below is my syntax. How do I plot predicted Poisson and negative binomial probabilities against the sample below?

data world;
input scores @@;
datalines;
5 1 6 3 2 1 2 1 1 2 1 3 3 3 3
4 1 1 1 2 1 3 2 2 3 7 3 3 7
4 3 3 3 2 4 2 0 3 3 3 2 4 2
1 1 1 3 7 3 2 2 2 5
;

proc means data=world n mean var;
run;
/* Mean= 2.67 and Variance=2.56. The data is a good canfidate for poisson distribution. */

proc genmod data=world;
run;

Accepted Solutions
Solution
Monday
SAS Employee
Posts: 384

## Re: proc genmod graphics for count data model fit assessment

Another example that produces both an observed vs. expected plot (using PROC COUNTREG) and a test of the fit (using PROC FREQ) is shown in this note.

All Replies
SAS Super FREQ
Posts: 4,237

## Re: proc genmod graphics for count data model fit assessment

[ Edited ]

Follow the example in the article "Fitting a Poisson distribution to data in SAS."

Occasional Contributor
Posts: 6

SAS Super FREQ
Posts: 4,237

Solution
Monday
SAS Employee
Posts: 384

## Re: proc genmod graphics for count data model fit assessment

Another example that produces both an observed vs. expected plot (using PROC COUNTREG) and a test of the fit (using PROC FREQ) is shown in this note.

☑ This topic is solved.