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 (July 2005, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 11 Jul 2005 13:20:57 -0400
Reply-To:     "Wright, Wendi" <wwright@ETS.ORG>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "Wright, Wendi" <wwright@ETS.ORG>
Subject:      SAS Tip - Saving stats using Proc Means
Comments: To: SAS Tips <sastips@ets.org>
Content-type: text/plain; charset=iso-8859-1

Have you ever needed to save statistics that you can produce using proc means into a SAS dataset? Here is the easiest way:

proc means data=dsname; var verb math crit; by gender; output out=outdsname n = nv mean = mnv mnm mnc std = stdv stdm stdc sum = sumv summ sumc; run;

The output statement in the proc means procedure allows you to specify what statistic you want and then what to call the variables in the new dataset. In this case, the output dataset will have 11 variables: gender, nv (calculated for the verb variable), then the mean, std, and sum for all three variables.

Enjoy! Wendi

************************************************************************** This e-mail and any files transmitted with it may contain privileged or confidential information. It is solely for use by the individual for whom it is intended, even if addressed incorrectly. If you received this e-mail in error, please notify the sender; do not disclose, copy, distribute, or take any action in reliance on the contents of this information; and delete it from your system. Any other use of this e-mail is prohibited. Thank you for your compliance.


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