BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hello dears SAS users
I have the following problem
when i ran this code:
proc sort data=sashelp.class out=class;
by sex;
run;
ods noproctitle;
ods rtf file="G:\Assens\prog_autres\forum_sas\qqplot.rtf";
ods graphics on;
ods select qqplot;

proc univariate data=class;
var weight;
by sex;
qqplot / normal(mu=est sigma=est);
run;

ods graphics off;
ods rtf close;

There is written before my qq plot,
Variable: Weight
How can i do to remove it ?
Is there a general options to remove this ?
Thank you.
2 REPLIES 2
Cynthia_sas
Diamond | Level 26
Hi:
I'm not exactly sure how UNIVARIATE manages it, but it seems that the "Variable: xxxxx" information is being sent by PROC UNIVARIATE as though it were a procedure title. As you observe from your code, however, using ODS NOPROCTITLE does not suppress this string.

You can "disappear" the "Variable: xxxxx" string by turning the foreground and background color to be the same value -- in the code below, I'm changing them both to white so they disappear against the RTF page, when the RTF file is opened in Microsoft Word.

I thought there might be a table (or graph) template method to get rid of the string, but I could not find it. Perhaps one of the ODS developers will have a better idea of how to approach this task.

cynthia
[pre]
proc sort data=sashelp.class out=class;
by sex;
run;

ods path work.temp(update) sashelp.tmplmst(read);

proc template;
define style styles.nopt;
parent=styles.rtf;
class ProcTitle /
background=white
foreground=white;
end;
run;

ods listing close;
ods noproctitle;
ods rtf file="c:\temp\qqplotf.rtf" style=styles.nopt;
ods graphics on;
ods select qqplot;
proc univariate data=class;
var weight;
by sex;
qqplot / normal(mu=est sigma=est);
run;

ods graphics off;

ods _all_ close;

[/pre]

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

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