hello, I'm trying to output a sas dataset for my one-sided p-values in proc freq step.
ods output CrossTabFreqs=want;
proc freq data=a;
where treatn="virus";
table TFRELPRC_STD/binomial(p=0.234 level="Y") ;
run;
I think you are looking for
ods output binomialtest=want;
for the p values. There will be one row, matching the displayed table.
You can look up the table names in the documentation for Proc Freq under the Details tab with the ODS Table Names and see which tables are created by which Tables options. Or use ODS TRACE on; and ODS trace off; around the procedure you use to see which tables are generated by your code.
If you one one way freqs then request table ONEWAYFREQS, not Crosstabfreqs.
proc freq data=a;
ods output binomialtest=binomialtest;
where treatn="virus";
table TFRELPRC_STD/binomial(p=0.234 level="Y") ;
run;
proc freq data=a;
where treatn="virus";
table TFRELPRC_STD/binomial(p=0.234 level="Y") ;
output out=want binomial;
run;
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.