So, I was using PROC PRINT in SAS EG (output using the default Excel report output options), and I noticed that it was printing each BY Variable on a separate tab, which is *not* what I want it to do (waaaaaaaay too many tabs). I thought it required a PAGEBY statement for this kind of behavior?
Anyway, is there any way that I can have my report sectioned out by my BY Variable, but have the entire report appear on one tab?
FYI, I also tried this with an explicit ODS Excel statement to see if that made a difference, just in case there was a weird option hiding in the SAS EG default that I wasn't aware of and it came out the same.
Here's the PROC PRINT code. As you can see, it's pretty simple.
proc print data=dataerrorname noobs;
Whew, that worked. I set the SHEET_INTERVAL="NONE" in the ODS Excel statement, and that did it. Must have had a different default than I realized. Thanks!
The default for Sheet_interval is "table". Since each of your by values creates a different table, at least as far as ODS output is concerned, each went to a separate sheet.
You would see different behavior if you ran Proc Univariate or some other procedure with multiple tables.
Then the BYGROUP option keeps all the tables of a single by value on a sheet.
Another option value to consider would be PROC to keep each procedure output on a single tab.
Secure your spot at the must-attend AI and analytics event of 2024: SAS Innovate 2024! Get ready for a jam-packed agenda featuring workshops, super demos, breakout sessions, roundtables, inspiring keynotes and incredible networking events.
Register by March 1 to snag the Early Bird rate of just $695! Don't miss out on this exclusive offer.
Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.
Find more tutorials on the SAS Users YouTube channel.