BookmarkSubscribeRSS Feed
sherry88
Calcite | Level 5

Hi,

 

I would like to know how to change all frequencies that are strictly under 10 (0-9) to a blank cell in the rounded data

 

Thank you!

3 REPLIES 3
PaigeMiller
Diamond | Level 26

Do you mean you want these frequencies to APPEAR as blank in a report? Do you mean you want to not use these cells in an analysis? Could you provide a few more details and show us a portion of your data?

--
Paige Miller
sherry88
Calcite | Level 5

I would like these frequencies to appear blank in the report

 

Please see more information attached

 

 

ballardw
Super User

A custom format applied to the statistic in the case of proc tabulate.

Perhaps

 

proc format library=work;
   value  myblank
   0 - 9 =' '
   ;
run;

proc tabulate data =  TITLE;
class CNS_DV 
	  URBAN_RURAL 
	  INDV_CLT_AGE_2018
	  INDV_CLT_GNDR_CD
 	  CLT_PREF_LANG_CD;
format URBAN_RURAL $URB_RUR.
	   INDV_CLT_AGE_2018 AGE_GROUPS.
	   INDV_CLT_GNDR_CD $CLT_GENDER.
 	   CLT_PREF_LANG_CD $LANG.;	
table (CNS_DV = 'Subdivision' * URBAN_RURAL  = 'Urban/Rural'), 
      (INDV_CLT_AGE_2018 = 'Age Groups' * INDV_CLT_GNDR_CD = '' * CLT_PREF_LANG_CD = '') 
        * (N=''*f=myblank.)
		  ;
run;

Other procedures would require different syntax to apply the format.

 

 

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 3 replies
  • 570 views
  • 1 like
  • 3 in conversation