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 (December 2008, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Sun, 14 Dec 2008 12:56:40 -0500
Reply-To:   "Howard Schreier <hs AT dc-sug DOT org>" <schreier.junk.mail@GMAIL.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   "Howard Schreier <hs AT dc-sug DOT org>" <schreier.junk.mail@GMAIL.COM>
Subject:   Re: Each group as representing one average

On Sun, 14 Dec 2008 11:27:38 -0600, Joe Matise <snoopy369@GMAIL.COM> wrote:

>I think the way I would do it would be to use the class statement to get >each group's frequency into a dataset, and then use PROC MEANS on that >dataset. > >-Joe

Or use an inline view in SQL:

proc sql; select mean(temp) as mean_age from (select mean(age) as temp from sashelp.class group by sex); quit;

>On Sun, Dec 14, 2008 at 10:07 AM, avi <aviben@bezeqint.net.il> wrote: > >> Hello, >> >> I have a Proc tabulate calculating the mean for a variable across all >> the dataset; >> >> Is there a way to directly (weight?) instruct that each group (a >> certain parameter in the dataset) will contribute one average so that >> the final result will be an average of all the groups averages? >> >> Thanks >> Avi >>


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