BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi, I'm using a fairly simple code to make a cross-tabulation table with grades 1 to 5 (pre-adjustment grades) down the side against grades 1 to 5 and 'Exclusions' (post-adjustment grades) across the top as follows:

proc tabulate data=work.current;
class before_adjustment after_adjustment /order=data;
classlev before_adjustment after_adjustment /s=[background=white];
table Before_Adjustment=' ' all={ label='Total' s=[background=vligb]},
N=' '*(After_Adjustment='Period 2 - Current' all={ label='Total' s=background=vligb]})*F=comma12./RTS=10.
box='Period 1 Previous' misstext=' ';
run;

The thing is, one of the columns on my table is called 'Exclusions' and I would like these figures excluded from the Total (or 'all') at the end of the table.
Does anyone know of any way of doing this?

Any help greatly appreciated!
2 REPLIES 2
ChrisNZ
Tourmaline | Level 20
You'll have to do your tweaked sum before hand I am afraid, as in:
[pre]proc summary data=sashelp.class nway noprint;
class AGE;
output out=CLASS;
run;
data TAB;
set CLASS;
if AGE <14 then TOT+_FREQ_;
label TOT= 'Total for <14';
run;
proc tabulate data=TAB;
var TOT _FREQ_;
class AGE;
table (AGE all='Total')*_FREQ_=''*sum=''*f=2.0 TOT*max='';
run;
deleted_user
Not applicable
Ok, thanks for your help!

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

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