Programming the statistical procedures from SAS

PROC GENMOD statistics

Accepted Solution Solved
Reply
Occasional Contributor
Posts: 6
Accepted Solution

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
/ d=binomial link=log;
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.

 


Accepted Solutions
Solution
‎03-01-2018 12:25 AM
SAS Employee
Posts: 386

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

View solution in original post


All Replies
SAS Employee
Posts: 386

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.

Occasional Contributor
Posts: 6

Re: PROC GENMOD statistics

[ Edited ]
Posted in reply to StatDave_sas

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

Solution
‎03-01-2018 12:25 AM
SAS Employee
Posts: 386

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

Occasional Contributor
Posts: 6

Re: PROC GENMOD statistics

Posted in reply to StatDave_sas

Thanks! This was very helpful.

☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 4 replies
  • 189 views
  • 0 likes
  • 2 in conversation