BookmarkSubscribeRSS Feed
Peter_Y
Calcite | Level 5

Hello:

   I need to run a serious of logistic regression and save the results in rtf/pdf. 

 

 

 

%macro regression(var);
ods exclude all;
proc logistic data=cohort descending;
model outcome= &var;
strata match;
ods output ParameterEstimates=ps;
run;

proc print data=ps;
run; %mend; ods rtf file='output.rtf' bodytitle;
title 'first regression'; %regression(var1); title 'second regression';
%regression(var2); ods rtf close;

The challenge is that the following text is always displayed in the output file, although ods exclude all is used. 

The LOGISTIC Procedure

 

Conditional Analysis

 

 

This seems to be associated with the bodytitle option. However, it is required to put the title in the body. Another option is to use

 

ods rtf exclude all;

However, if rtf destination is not open, the above code will generate an error. I am wondering whether there is a generic solution to this problem?

 

Thanks,

Peter

 

2 REPLIES 2
Peter_Y
Calcite | Level 5

Thanks. I tried noptitle and it works partially that the title of proc logistic 

The LOGISTIC Procedure

is removed. However, the subtitle for the strata statement

Conditional Analysis

is still displayed. 

 

Anyway to suppress it?

 

Thanks,

Peter

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 1231 views
  • 0 likes
  • 2 in conversation