LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (November 2008, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Sun, 2 Nov 2008 11:45:04 -0500
Reply-To:     Lou <lpogoda@HOTMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Lou <lpogoda@HOTMAIL.COM>
Organization: Aioe.org NNTP Server
Subject:      Re: Means
Comments: To: sas-l@uga.edu

"Randy" <randistan69@HOTMAIL.COM> wrote in message news:200811021344.mA2BmvKL012869@malibu.cc.uga.edu... > Dear all: > Is there a one step data process to calculate the means of the entire > sample; and the means according to the class. > So, for example; > > Class VarA > A 20 > A 31 > B 22 > A 12 > B 4 > > I want the mean of VarA for all the observations and according to Class A > and Class B. I would like to do this in one data step. Is this possible?

Yes, it's possible, but it's ill advised. Generally, if there's a function or procedure available for a particular calculation, you should use it rather than programming it "by hand", so to speak. In this case, PROC MEANS or PROC SUMMARY will do what you want.


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