DATA Step, Macro, Functions and more

Analysis variables in SAS

Reply
Occasional Contributor
Posts: 13

Analysis variables in SAS

[ Edited ]

While using the Analysis variable in SAS, this variable heading automatically displayed in report. how to remove this heading. This is My code : 

 

proc report data=Work.Channelsummary Spanrows style(header)=[bordercolor=BLACK 
		background=#97291E foreground=white font=(zurichbt, 8pt) 
		font_weight=bold ] style(report)=[bordercolor=black borderwidth=1pt 
		font=(zurichbt, 8pt)] style(column)=[background=#FFFFFF bordercolor=#000000 
		font=(zurichbt, 8pt) vjust=middle 
		cellheight=.10in ] style(summary)=[font_face=White] center split='_';
	column('State & RH Channel Wise Summary :' Zone RHName)(('Total Allocation' 
		ChannelAllocation1, TotalCount))('Resolved' ChannelAllocation1, 
		TRCount)('Part Payment' ChannelAllocation1, PPCount)('Resolution %' 
		ChannelAllocation1, Resolved);

	/*row ('' Resolution)('TOTAL' COUNT ELB); */
	define Zone / 'Zone' group;
	define RHName / 'RH Name' group;
	define ChannelAllocation1 / group across;
	define TotalCount / analysis sum Width=5 center;
	define TRCount / analysis sum Width=5 center;
	define PPCount / analysis sum Width=5 center;
	rbreak before / summarize;
	compute before;

		if _break_='_RBREAK_' then
			do Zone="Total";
				call define (_row_, 'style', 'style=[background=CXFF8000 foreground=Black bordercolor=black font=(ZurichBt,8pt)font_weight=bold]');
			end;
	endcomp;
	define ChannelAllocation1 / across;
	define Resolved / analysis format=Percent11.0 center;
run;

title1;
Super User
Posts: 7,762

Re: Analysis variables in SAS

Please use the "little running man" symbol to open a window for entering SAS code, and copy/paste the code there from EG (or Studio). The way you posted your code, it has no formatting at all.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Super User
Posts: 7,762

Re: Analysis variables in SAS

Formatted code:

proc report
  data=Work.Channelsummary
  Spanrows
  style(header)=[
    bordercolor=BLACK
    background=#97291E
    foreground=white
    font=(zurichbt,8pt)
    font_weight=bold
  ]
  style(report)=[
    bordercolor=black
    borderwidth=1pt
    font=(zurichbt,8pt)
  ]
  style(column)=[
    background=#FFFFFF
    bordercolor=#000000
    font=(zurichbt,8pt)
    vjust=middle
    cellheight=.10in
  ]
  style(summary)=[
    font_face=White
  ]
  center
  split='_'
;
column
  ('State & RH Channel Wise Summary :' Zone RHName)
  (('Total Allocation' ChannelAllocation1,TotalCount))
  ('Resolved' ChannelAllocation1,TRCount)
  ('Part Payment' ChannelAllocation1,PPCount)
  ('Resolution %' ChannelAllocation1,Resolved)
;
/*row ('' Resolution)('TOTAL' COUNT ELB); */
define Zone / 'Zone' group;
define RHName / 'RH Name' group;
define ChannelAllocation1 / group across;
define TotalCount / analysis sum Width=5 center;
define TRCount / analysis sum Width=5 center;
define PPCount / analysis sum Width=5 center;
rbreak before / summarize;
compute before;
  if _break_ = '_RBREAK_'
  then do;
    Zone="Total";
    call define (_row_,'style', 'style=[background=CXFF8000 foreground=Black bordercolor=black font=(ZurichBt,8pt)font_weight=bold]' );
  end;
endcomp;
define ChannelAllocation1 / across;
define Resolved / analysis format=Percent11.0 center;
run;
title1;

Could you please supply a piece of the report and indicate which element you want removed?

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 13

Re: Analysis variables in SAS

Posted in reply to KurtBremser

screenshot.png
Occasional Contributor
Posts: 13

Re: Analysis variables in SAS

Posted in reply to KurtBremser

screen shot attached.


screenshot.png
Super User
Posts: 7,762

Re: Analysis variables in SAS

Have you looked at the noheader option of proc report?

For this, and how to supress individula column headers, https://communities.sas.com/t5/ODS-and-Base-Reporting/Hide-PROC-Report-column-names/td-p/61639 might be interesting.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Ask a Question
Discussion stats
  • 5 replies
  • 238 views
  • 0 likes
  • 2 in conversation