0% found this document useful (0 votes)
30 views2 pages

Proc Freq

The document demonstrates how to use the PROC FREQ procedure in SAS to generate frequency tables and contingency tables for one and two variables. It shows different options that can be used with PROC FREQ like MISSPRINT, MISSING, LIST, and ORDER=DATA.

Uploaded by

naveen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
30 views2 pages

Proc Freq

The document demonstrates how to use the PROC FREQ procedure in SAS to generate frequency tables and contingency tables for one and two variables. It shows different options that can be used with PROC FREQ like MISSPRINT, MISSING, LIST, and ORDER=DATA.

Uploaded by

naveen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

data ds1;

input a b @@;
cards;
12 21 .2 .. 11 21
;
run;

if u not specify the dataset it will take the recent execute dataset

proc freq;
title 'NO TABLES STATEMENT';
run;

missprint;

proc freq;
tables a / missprint;
title '1-WAY FREQUENCY TABLE WITH MISSPRINT OPTION';
run;

two way freq;

proc freq;
tables a*b;
title '2-WAY CONTINGENCY TABLE';
run;

data ds2;
input a b @@;
cards;
12 21 .2 .. 11 31
;
run;

proc freq;
tables a*b;
title '2-WAY CONTINGENCY TABLE';
run;

proc freq;
tables a*b / missprint;
title '2-WAY CONTINGENCY TABLE WITH MISSPRINT OPTION';
run;
proc freq;
tables a*b / missing;
title '2-WAY CONTINGENCY TABLE WITH MISSING OPTION';
run;

proc freq;
tables a*b / list;
title '2-WAY FREQUENCY TABLE';
run;

proc freq;
tables a*b / list missing;
title '2-WAY FREQUENCY TABLE WITH MISSING OPTION';
run;

proc freq;
tables a*b / list;
title '2-WAY FREQUENCY TABLE WITH SPARSE OPTION';
run;

proc freq order=data;


tables a*b / list;
title '2-WAY FREQUENCY TABLE, ORDER=DATA';
run;

You might also like