Hello,
I am new to SAS and while I was learning I was using proc report for sashelp.class, and then fetching the output in an rtf format to see the output but in reality I got a simple tabular format and didn't get expected results.
Here's the code:
title "ABC school";
title2 "Students report";
footnote "This is a sample report.Don't rely on it";
ods rtf file="/home/u62925501/MyFolder/sample.rtf";
proc report data=sashelp.class (obs =10) nowd headline headskip split='*' out= ds1;
columns ("Student Class data"("Details" name sex) ("Measures" age height weight));
define sex/group;
break after sex/summarize;
run;
ods rtf close;
Here's the output coming in rtf file:
Expected output is:(note it is just a sample image)
Thanks in advance
Your expectations are wrong. PROC REPORT gave you exactly what you asked for.
If you want something like the text output shown, you'd have to write code to get that, or perhaps use the %TABLEN macro.
SAS ODA = SAS OnDemand for Academics (ODA).
For the rest ... , no clue what you are talking about ☹️.
Please elaborate !
Koen
Hello,
I am new to SAS and while I was learning I was using proc report for sashelp.class, and then fetching the output in an rtf format to see the output but in reality I got a simple tabular format and didn't get expected results.
Here's the code:
title "ABC school";
title2 "Students report";
footnote "This is a sample report.Don't rely on it";
ods rtf file="/home/u62925501/MyFolder/sample.rtf";
proc report data=sashelp.class (obs =10) nowd headline headskip split='*' out= ds1;
columns ("Student Class data"("Details" name sex) ("Measures" age height weight));
define sex/group;
break after sex/summarize;
run;
ods rtf close;
Here's the output coming in rtf file:
Expected output is:(note it is just a sample image)
Thanks in advance
Hello @v307086 , don't post the same question twice, and don't change the topic of a thread in the middle. Your PROC REPORT question should be discussed in your other thread at https://communities.sas.com/t5/SAS-Programming/proc-report-in-SAS-ODA/td-p/855012/jump-to/first-unre...
In SAS Studio, you can call up any table to view it, and leave it viewable for as long as you want (in other words until you close it).
Step 1: Go to Libraries on the left.
Step 2: Expand "My Libraries".
Step 3: Expand the library of interest (often the WORK library).
Step 4: double-click on the data set of interest.
When you next run code, the data set you just opened remains open, however "My Libraries" collapses and you have to go through steps 2 through 4 again to get to that library. I do find this incredibly annoying and a major drawback of SAS Studio, making programming much more time consuming, but it is possible.
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
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.