I'm estimating odds ratio between m_pattern (three categories) and c_pattern (three categories) with the following code.
I found macro for logistics regression with ordinal outcomes, but I failed to find macro for outcomes with more than two categories.
I wonder if there are macro for batch analysis and auto OR table ouput?
proc logistic data=diet.dietary;
class
m_pattern2 (param=ref ref="1");
model c_pattern2 (ref="1")=m_pattern2 /link=glogit rl cl;
run;
@Frankzzf wrote:
I apologize for not being clear.
i mean a marco that could output word documents with created OR tables from logistic procedure
Macros are not needed. You can use ODS RTF or ODS WORD. Example:
ods rtf file="myfile.rtf";
proc logistic data=...;
...
run;
ods rtf close;
I don't understand what you are trying to do .
You should know if your response/Y variable is nominal variable,you would get TWO model separatedly (1 vs 3 and 2 vs 3 if take 3 as a reference level).
And check the example of Doc:
Nominal Response Data: Generalized Logits Model
https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/statug/statug_logistic_examples04.htm
PROC LOGISTIC should do this without a macro. What is it you want that PROC LOGISTIC doesn't do?
@Frankzzf wrote:
I apologize for not being clear.
i mean a marco that could output word documents with created OR tables from logistic procedure
Macros are not needed. You can use ODS RTF or ODS WORD. Example:
ods rtf file="myfile.rtf";
proc logistic data=...;
...
run;
ods rtf close;
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.
Find more tutorials on the SAS Users YouTube channel.