LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (January 2007, week 5)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 29 Jan 2007 16:01:41 -0500
Reply-To:     Ya Huang <ya.huang@AMYLIN.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Ya Huang <ya.huang@AMYLIN.COM>
Subject:      Re: Proc format to suppress data,
              then proc tabulate= columns don't add up
Comments: To: diaphanosoma@HOTMAIL.COM

My guess is that you put the format in a wrong place. I have no problem suppress the number yet to get the 'ALL' correctly:

proc format; value toosmall low-13=' --' other=[best8.] ;

proc tabulate data=sashelp.class (where=(sex='F')); class name; var age; table name='' all, age*sum=''*f=toosmall8.; run;

--------------------------------- | | Age | |----------------------+--------| |Alfred | 14| |----------------------+--------| |Alice | --| |----------------------+--------| |Barbara | --| |----------------------+--------| |Carol | 14| |----------------------+--------| |Jane | --| |----------------------+--------| |Janet | 15| |----------------------+--------| |Joyce | --| |----------------------+--------| |Judy | 14| |----------------------+--------| |Louise | --| |----------------------+--------| |Mary | 15| |----------------------+--------| |All | 133| ---------------------------------

On Mon, 29 Jan 2007 12:19:11 -0800, diaphanosoma@HOTMAIL.COM wrote:

>Greetings, > >I have to produce a data table with values less than 5 suppressed. I >did a proc format > >PROC FORMAT; > VALUE NOSMALLVALUES 0,1,2,3,4 = '- ' > ; > RUN; > >to make a dash to hide those values. > >Then I need to do a proc tabulate of "salesman" by county with an All >column to add up their sales for each county. > >SAS will only sum the numbers and not give the true total. So if >salesman1 has has three sales in each of the three counties I would >like the All to add to nine and not '-'. > >A similar problem would be to create a group of "loser" salesmen and >group them if their total sales are less than 20 dollars or some >number. Can this be done directly in Tabulate, or do I need to sum the >regional sales in proc means and then take that output for proc >tabulate? > >Thanks, > >Brew


Back to: Top of message | Previous page | Main SAS-L page