BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
AndrewZ
Quartz | Level 8

I invoke PROC FREQ like the following, and I would prefer to clean up the output.  Omitting Fisher's exact test would be a good start.  Also, I only need the basic Chi-Square statistic and not the 6 others.

proc freq data= year_ago;

    tables a * b / chisq nocol nopercent;

run;

Do I need some obscure ODS commands, or output to a data set and go from there, or is there an easier way?

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

You can select the tables/results you'd like to see using the ODS SELECT TABLENAMES statement.

To figure out the ODS TABLE names check the docs for proc freq or run your procedure with ODS TRACE ON;

Just a note though, in my version I think fishers only shows up when it thinks its necessary, versus all the time.

ods select crosstabfreqs chisq;

proc freq data=sashelp.heart;

table Chol_Status*sex/chisq nocol nopercent;

run;

View solution in original post

1 REPLY 1
Reeza
Super User

You can select the tables/results you'd like to see using the ODS SELECT TABLENAMES statement.

To figure out the ODS TABLE names check the docs for proc freq or run your procedure with ODS TRACE ON;

Just a note though, in my version I think fishers only shows up when it thinks its necessary, versus all the time.

ods select crosstabfreqs chisq;

proc freq data=sashelp.heart;

table Chol_Status*sex/chisq nocol nopercent;

run;

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 1148 views
  • 0 likes
  • 2 in conversation