Date: Fri, 6 Apr 2007 11:16:04 -0400
Reply-To: Jack Clark <JClark@CHPDM.UMBC.EDU>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Jack Clark <JClark@CHPDM.UMBC.EDU>
Subject: Re: Proc Freq
Content-Type: text/plain
RAMS,
Instead of the ODS output, you could use the OUT= option on the TABLES
statement. You can use the NOPRINT option and still produce an output
dataset from the FREQ output.
Proc freq data = ques1 noprint;
Tables response / out=q1;
Run;
This will produce an output dataset called q1 with the variables RESPONSE,
COUNT and PERCENT. In your example it looks like you were suppressing the
cumulative counts and percents. These are not included in the default
dataset when using the OUT= option in PROC FREQ. If you ever do want them,
add the OUTCUM option to the TABLES statement.
You are able to have multiple TABLES statements within the same PROC FREQ if
you need output tables for more than one variable.
Hope this helps.
Jack Clark
Research Analyst
Center for Health Program Development and Management
University of Maryland, Baltimore County
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of RAMS
Sent: Friday, April 06, 2007 11:03 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Proc Freq
Dear All,
I have a data of students opinion about their teachers. I
need calcuate a response (1 to 5) pecentage of each question. And i
need to save these counts and percentages in a new dataset.
To do that i wrote a code of
ods output OneWayFreqs=q1;
proc freq data=ques1;
tables response/nocum;
run;
I am getting this output in the output page, actually i
dont need a PROC FREQ OUTPUT. So i wrote "NOPRINT" in Proc Freq.
But SAS is not creating a new sas dataset if i write "NOPRINT". How
to solve this issue.
Anyone please help me.
Thanks in advance.