The SAS Output Delivery System and reporting techniques

Proc Report Conditional Borders

Reply
Contributor
Posts: 33

Proc Report Conditional Borders

Hi! I was hoping someone could help me out with figuring out how to add a border only to the last row where panel = 1, panel =2 and panel =3.

The data loks something like this

 

panel   job  case

1      doctor    x

1      nurse     x

1      doctor    y

2      doctor    z

2      stats      x

2      stats      z

 

 

 

This is what my code looks like now, however, there is a line that shows after every row where panel=1

 

ods listing close;

ods escapechar = '^';

ods noproctitle;

options nodate number;

footnote;

ODS RTF FILE = 'C:\Desktop\out.rtf'

author = 'NN'

title = XX

bodytitle

startpage = no

style =sasdocprinter;

options papersize = legal

papersize = legal

leftmargin = 1in

rightmargin = 1in

orientation = portrait; /*landscape*/

title1 font = 'Times New Roman' height = 11pt justify = center underlin = 0 color = black bcolor = white 'Table 3: Outiers using Non-Transformed Data';

footnote1 font = 'Times New Roman' height = 11pt justify = center underlin = 0 color = black bcolor = white 'XXX.';

 

proc report data = perm.outliers nowindows headline headskip missing center

style(report)=[cellspacing=2 borderwidth=2 bordercolor=black]

style(header) = {font_weight = light font_face = 'Times New Roman' font_size = 11pt just = center cellheight=.4in }

style(column) = {font_face = 'Times New Roman' font_size = 11pt just = center /*asis = on*/ cellheight=.22in};

column panel job case ;

define panel / display /*order group*/ ' /Panel' center style=[cellwidth=15mm] ;

define job / display ' /Job' center style=[cellwidth=20mm];

define case / display ' /Case' center style=[cellwidth=15mm];

 

 

compute panel ;

if panel=1;

call define(_row_,'style', 'style=[foreground=black background=white borderbottomcolor=black borderbottomwidth=3]');

endcomp;

 

 

 

endcomp;

run;

ods rtf close;

SAS Super FREQ
Posts: 8,958

Re: Proc Report Conditional Borders

Posted in reply to nirali514
Hi:
I am not sure you can set the borders conditionally or whether the destination makes a difference. This would be a better question to ask of Tech Support.

cynthia
Contributor
Posts: 33

Re: Proc Report Conditional Borders

Posted in reply to Cynthia_sas

Thank you Cynthia!

Ask a Question
Discussion stats
  • 2 replies
  • 111 views
  • 0 likes
  • 2 in conversation