- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I used crude log-binomial regression with GEE for my analysis. When I ran the below code I get this error message.
proc genmod data = myproject_1e descending;
class ParticipantID;
class state_marijuana_legal_status1 (ref='3');
model Marijuana_Use2 = state_marijuana_legal_status1/ dist=binomial; link=log;
repeated subject=ParticipantID/type=exch;
run;
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
one semi-colon ( ; ) too much ...
model
Marijuana_Use2 = state_marijuana_legal_status1 / dist=binomial link=log;
SAS/STAT User's Guide
The GENMOD Procedure
MODEL Statement
https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/statug/statug_genmod_syntax22.htm
Note there's also a PROC GEE !
BR, Koen
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi, Thank you for your comment.
I was able to run the code after removing the extra semi colon but I get this warning in my log . I have attached both my output and log screen shot. Can you look into it and let me know if I need to modify anything. Thank you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
So, you get the warning :
WARNING: The number of response pairs for estimating correlation is less than or equal to the number of regression parameters. A simpler correlation model might be more appropriate.
That warning message is the result of having very few measurements at some time points. With few clusters having measurements at some time point(s), there is insufficient data available to estimate correlations involving those time points. This is particularly likely if you use the unstructured correlation matrix (TYPE=UN) and have clusters of varying sizes. If there is only one, or very few, clusters of the largest size, then this condition occurs. The solution is either to remove the few clusters with the largest size or to simply use a simpler correlation structure. The GEE method is robust to the choice of correlation structure. So, even if you select a structure that doesn't match the true structure, you still get statistically consistent estimators. As a result, you can use the method without needing to precisely define the nested correlation structure. Many analysts routinely use simple structures such as TYPE=IND or TYPE=EXCH.
Also, note that PROC GEE is a newer procedure specifically for fitting the GEE model and is the recommended procedure when fitting that model. It adds support for nominal multinomial response data and data that are missing at random and might perform better in some cases.
See also ( look for 'GEE' )
- Usage Note 22871: Types of logistic (or logit) models that can be fit using SAS®
https://support.sas.com/kb/22/871.html - Usage Note 46997: Estimating the risk (proportion) difference for matched pairs data with binary response
https://support.sas.com/kb/46/997.html
BR, Koen
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
To add to what what @sbxkoenk noted, based on the SUBJECT=ParticipantId specification in your code, I suspect you might be running an analysis where you have one measurement from each subject and are using the GEE model to get the empirical/robust/sandwich covariance matrix estimate. If that is the case, then specifying TYPE=EXCH, would be a likely cause for that WARNING message, since estimating the exchangeable working correlation structure would require clusters with two or more observations. As mementioned in the note @sbxkoenk rreferenced, you can switch to using an independent working correlation structure. The independent working correlation structure is used by default if you omit the TYPE= option.