Hi all
I wonder if anyone pease can help me with this code, I am trying to get the Kaplan Meier curves in black/white but not able to do it. Tired style=journal but it didnt work..
Any suggestions please
data _null_;
%let url = //support.sas.com/documentation/onlinedoc/stat/ex_code/131;
infile "http:&url/templft.html" device=url;
file 'macros.tmp';
retain pre 0;
input;
if index(_infile_, '</pre>') then pre = 0;
if pre then put _infile_;
if index(_infile_, '<pre>') then pre = 1;
run;
%inc 'macros.tmp' / nosource;
proc template;
delete Stat.Lifetest.Graphics.ProductLimitSurvival / store=sasuser.templat;
delete Stat.Lifetest.Graphics.ProductLimitSurvival2 / store=sasuser.templat;
run;
%ProvideSurvivalMacros
%let StepOpts = lineattrs=(thickness=1.5 );
%let TitleText0 = "Kaplan Meier curve ";
%let TitleText1 = &titletext0 " FOOOOR " STRATUMID;
%let TitleText2 = &titletext0;
%let yOptions = label="Proportion" linearopts=(viewmin=0 viewmax=1.0);
%let xOptions = label="Years" offsetmin=.0;
%let LegendOpts = title="Histopathology" location=inside autoalign=(Bottom);
%let InsetOpts = autoalign=(TOPRIGHT BOTTOMRIGHT TOP BOTTOM) border=true BackgroundColor=GraphWalls:Color Opaque=true;
%CompileSurvivalTemplates
ods rtf file='c:\Users\Ta\Desktop\PSC KM.doc' style=journal;
ods listing GPATH = 'c:\g' image_dpi = 400;
ods graphics / reset width=7in height=6in imagename='KM';
ods html sge=on;
ods select lifetest.survivalplot;
proc lifetest data=p atrisk plots=survival(/*atrisk (atrisktickonly outside)*/ test /*cb*/ ) notable;
strata pad;
time ltx_fu*death(0);
run;
ods rtf close;
ods select all;
ods listing close;
ods graphics / reset;
ods rtf close;
Any help is appreciated
kind regards
Solved using:
%let GraphOpts = attrpriority=none DataContrastColors=(black) DataColors=( black);
Solved using:
%let GraphOpts = attrpriority=none DataContrastColors=(black) DataColors=( black);
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.