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 (October 2001, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 10 Oct 2001 18:28:11 -0700
Reply-To:     "Karsten M. Self" <kmself@IX.NETCOM.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "Karsten M. Self" <kmself@IX.NETCOM.COM>
Subject:      Re: count for each level of an categorical variable
In-Reply-To:  <8004473a.0110101705.65e6fcc7@posting.google.com>; from
              shpzh2000@YAHOO.COM on Wed, Oct 10, 2001 at 06:05:05PM -0700
Content-Type: multipart/signed; micalg=pgp-sha1;
protocol="application/pgp-signature";

on Wed, Oct 10, 2001 at 06:05:05PM -0700, Rich (shpzh2000@YAHOO.COM) wrote: > My sorting problem got solved. Thank you all very much. > > Now I came to another prob.^:^ > > The 8GB dataset has 3.5 millon obs. There is a categorical variable > with a lot of levels. For each level, I would like to know the > corresponding count. I used PROC FREQ, but it used up all my memory > pretty soon. Is there any trick to get around this problem? Seems like > the PROC FREQ is very memory-consuming, right?

Post your code and FULLSYSTIMER output.

Alternative:

proc sql; select distinct var, count( * ) from table group by var ; quit;

-- Karsten M. Self <kmself@ix.netcom.com> http://kmself.home.netcom.com/ What part of "Gestalt" don't you understand? Home of the brave http://gestalt-system.sourceforge.net/ Land of the free Free Dmitry! Boycott Adobe! Repeal the DMCA! http://www.freesklyarov.org Geek for Hire http://kmself.home.netcom.com/resume.html


[application/pgp-signature]


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