ods html close; %let gpath=C:\; %let w=4in; %let h=2.5in; %let dpi=200; ods listing gpath="&gpath" image_dpi=&dpi; /*--Long categories--*/ data split; input Name $1-30 Value; datalines; SAS Base SGPLOT Procedure 200 SAS Base REPORT Procedure 500 SAS/STAT LIFETEST Procedure 100 SAS/STAT REG Procedure 200 ; run; /*--Long categories with split char--*/ data split_char; input Name $1-30 Value; datalines; SAS Base: SGPLOT Procedure 200 SAS Base: REPORT Procedure 500 SAS/STAT: LIFETEST Procedure 100 SAS/GRAPH: GCHART Procedure 200 ; run; /*--Default splitting--*/ title 'Some Measure by Procedure Name'; footnote j=l 'Using FitPolicy=Split'; ods graphics / reset width=&w height=&h imagename='Split_Default'; proc sgplot data=split noborder; hbar name / response=Value dataskin=pressed nostatlabel fillattrs=graphdata1; yaxis fitpolicy=split valueattrs=(weight=bold size=7) display=(noticks noline nolabel); xaxis display=(noticks nolabel noline) grid; run; /*--Split on a specific character--*/ title 'Some Measure by Procedure Name'; footnote j=l 'Using FitPolicy=Split with SplitChar'; ods graphics / reset width=&w height=&h imagename='Split_Char'; proc sgplot data=split_char noborder; hbar name / response=Value dataskin=pressed nostatlabel fillattrs=graphdata2; yaxis fitpolicy=split splitchar=':' valueattrs=(weight=bold size=7) display=(noticks noline nolabel); xaxis display=(noticks nolabel noline) grid; run; /*--Retain split character in the display--*/ title 'Some Measure by Procedure Name'; footnote j=l 'Using FitPolicy=Split with SplitChar and NoDrop'; ods graphics / reset width=&w height=&h imagename='Split_Char_NoDrop'; proc sgplot data=split_char noborder; hbar name / response=Value dataskin=pressed nostatlabel fillattrs=graphdata3; yaxis fitpolicy=split splitchar=':' splitcharnodrop valueattrs=(weight=bold size=7) display=(noticks noline nolabel); xaxis display=(noticks nolabel noline) grid; run;