I have searched the community, and find no related post.
So far, I can not find a complete style guide for SAS.
Hope someone can provide such information, or any good coding standard.
Thanks!
Pick one.
https://lexjansen.com/search/searchresults.php?q=style%20guide
Keep an eye on dates on the papers, SAS is from the 1970's so there's a lot of old stuff laying around the internet.
@GFW wrote:
I have searched the community, and find no related post.
So far, I can not find a complete style guide for SAS.
Hope someone can provide such information, or any good coding standard.
Thanks!
Hi:
There's no Strunk and White or Chicago Style manual, if that's what you mean. There are a lot of papers on good coding practices. In Programming 1, we have some basic recommendations for program style:
1) start each statement on a new line
2) indent lines and use white space to aid readability.
3) use comments
As an example, which program would you rather work with?
proc print data=sashelp.class;title 'my title'; var sex age name height weight; run;
proc print data=sashelp.class;
title 'my title';
var sex age name height weight;
run;
** This is my first report;
proc print data=sashelp.class;
title 'my title';
var sex age name height weight;
run;
They are all the same program, I'd rather work with 3 or 2. Program 1 would make me crazy. But SAS doesn't care about readability, so it doesn't care.
Cynthia
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
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.