Fluorite | Level 6

## PROC GENMOD statistics

Good afternoon all, I hope everyone is having a great day. I am writing because I am working with cross-sectional complex survey data and generating a log-binomial model (for prevalence ratios). The default statistical test used for each regression term is a Z statistic. Since this is a sample (without the assumption of population normality) I want to generate t statistics (or F statistics) for each term instead. How do I accomplish this? Below is an example of my code.

PROC GENMOD data=Cancer;
CLASS Cluster Stratum;
MODEL Kidney (event='1') = BMI Gluc
TITLE 'Model 1';
WEIGHT Weight;

REPEATED SUBJECT = Cluster (Stratum);
RUN;

I appreciate any help you can provide. Thanks, and have a great rest of the day.

1 ACCEPTED SOLUTION

Accepted Solutions
SAS Super FREQ

## Re: PROC GENMOD statistics

The parameter tests produced for a GEE model in PROC GENMOD are large-sample Wald (Z) tests. If you particularly want to use t-tests instead, then you can simply use the PROBT function in the DATA step with the statistic value and the error degrees of freedom as arguments. For example, the following produces the t-test p-value for the Smoke predictor in the GEE example in the Getting Started section of the GENMOD documentation.

``````data _null_;
p = 1-probt(-0.2036,60);
put p=;
run;

``````

The result is shown in the log.

``````30     data _null_;
31     p = probt(-0.2036,60);
32     put p=;
33     run;

p=0.4196775261
NOTE: DATA statement used (Total process time):
real time           0.01 seconds
cpu time            0.01 seconds

``````
4 REPLIES 4
SAS Super FREQ

## Re: PROC GENMOD statistics

If you have survey data you should not use PROC GENMOD. Only the survey procedures have the variance estimators necessary for a proper analysis of survey data. Unfortunately, there is no survey procedure that will fit a log binomial model, but you could use PROC SURVEYLOGISTIC for fitting a logistic model to binary response data.

Fluorite | Level 6

## Re: PROC GENMOD statistics

Thank you so much for the information. If I were using unweighted, unstratified, unclustered data (which has none of the complex survey data parameters) how would I go about reporting a t or F test for regression terms in a sample in PROC GENMOD (instead of the default Z test)?

Thanks,

Rod Turpin

SAS Super FREQ

## Re: PROC GENMOD statistics

The parameter tests produced for a GEE model in PROC GENMOD are large-sample Wald (Z) tests. If you particularly want to use t-tests instead, then you can simply use the PROBT function in the DATA step with the statistic value and the error degrees of freedom as arguments. For example, the following produces the t-test p-value for the Smoke predictor in the GEE example in the Getting Started section of the GENMOD documentation.

``````data _null_;
p = 1-probt(-0.2036,60);
put p=;
run;

``````

The result is shown in the log.

``````30     data _null_;
31     p = probt(-0.2036,60);
32     put p=;
33     run;

p=0.4196775261
NOTE: DATA statement used (Total process time):
real time           0.01 seconds
cpu time            0.01 seconds

``````
Fluorite | Level 6