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

hello every one,

 

i am running a proc summary on large number of table, now the output is like that

sum1.PNGsum2.PNG

 

i need your help on how could i make the output table (second capture) as the first capture.

i would be so grateful.

 

the code is as follow :

 

proc summary data=x print n nmiss min max mean std;

output out=y;

VAR _NUMERIC_;

run;

 

thank you so much

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User
ods select none;
proc means data=x print n nmiss min max mean std stackods;

VAR _NUMERIC_;
ods output summary = Y;
run;
ods select all;


proc print data=Y;
run;

I have examples of the different options here:

https://github.com/statgeek/SAS-Tutorials/blob/master/proc_means_basic.sas

 

You can run the code in your own SAS instance to see the output. 


@aloou wrote:

hello every one,

 

i am running a proc summary on large number of table, now the output is like that

sum1.PNGsum2.PNG

 

i need your help on how could i make the output table (second capture) as the first capture.

i would be so grateful.

 

the code is as follow :

 

proc summary data=x print n nmiss min max mean std;

output out=y;

VAR _NUMERIC_;

run;

 

thank you so much


 

View solution in original post

6 REPLIES 6
PaigeMiller
Diamond | Level 26
proc summary data=x n nmiss min max mean std STACKODSOUTPUT;
    VAR _NUMERIC_;
    output out=y ;
run;
--
Paige Miller
aloou
Obsidian | Level 7

Mr Miller i am so grateful for all the help you provide.

 

i just tried what you wrote but still i am getting same tables as capture 2.

PaigeMiller
Diamond | Level 26

Show me the exact code you used, and the exact output it produces. Use the running man icon to provide the code. Show us the output via a screen capture, using the "Photos" button. No attachments, please.

--
Paige Miller
Tom
Super User Tom
Super User

Try using the ODS OUTPUT statement to get the table behind that report. 

 

You will need to know what its name is so use ODS TRACE to see what PROC SUMMARY names its ODS outputs.

Reeza
Super User
ods select none;
proc means data=x print n nmiss min max mean std stackods;

VAR _NUMERIC_;
ods output summary = Y;
run;
ods select all;


proc print data=Y;
run;

I have examples of the different options here:

https://github.com/statgeek/SAS-Tutorials/blob/master/proc_means_basic.sas

 

You can run the code in your own SAS instance to see the output. 


@aloou wrote:

hello every one,

 

i am running a proc summary on large number of table, now the output is like that

sum1.PNGsum2.PNG

 

i need your help on how could i make the output table (second capture) as the first capture.

i would be so grateful.

 

the code is as follow :

 

proc summary data=x print n nmiss min max mean std;

output out=y;

VAR _NUMERIC_;

run;

 

thank you so much


 

aloou
Obsidian | Level 7

Thank you Mr Reeza , the code is working well.

i am so grateful for your help

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 6 replies
  • 1524 views
  • 1 like
  • 4 in conversation