Welcome to MSUG: Michigan SAS Users Group

 
  • Home
  • News
  • Meetings
  • Links
  • Contact Us
  • Presentations
  • Jobs

Merge With Caution: How to Avoid Common Problems when Combining SAS Datasets - Josh Horstman, Nested Loop Consulting

Although merging is one of the most frequently performed operations when manipulating SAS datasets, there are many problems which can occur, some of which can be rather subtle. This paper examines several common issues, provides examples to illustrate what can go wrong and why, and discusses best practices to avoid unintended consequences when merging.

Click here to download the companion paper.

Let the CAT Out of the Bag: String Concatenation in SAS 9 - Josh Horstman, Nested Loop Consulting

Are you still using TRIM, LEFT, and vertical bar operators to concatenate strings? It's time to modernize and streamline that clumsy code by using the string concatenation functions introduced in SAS® 9. This paper is an overview of the CAT, CATS, CATT, and CATX functions introduced in SAS® 9, and the new CATQ function added in SAS® 9.2. In addition to making your code more compact and readable, this family of functions also offers some new tricks for accomplishing previously cumbersome tasks.

Click here to download the companion paper.

Beyond IF THEN ELSE: Techniques for Conditional Execution of SAS® Code -
Josh Horstman, Nested Loop Consulting

Nearly every SAS® program includes logic that causes certain code to be executed only when specific conditions are met. This is commonly done using the IF...THEN...ELSE syntax. In this paper, we will explore various ways to construct conditional SAS logic, including some that may provide advantages over the IF statement. Topics will include the SELECT statement, the IFC and IFN functions, the CHOOSE and WHICH families of functions, as well as some more esoteric methods. We'll also make sure we understand the difference between a regular IF and the %IF macro statement.

Click here to download the companion paper.

Picture

About the Author

Josh Horstman is an independent statistical programmer based in Indianapolis with 20 years experience in the life sciences industry. He is a SAS® Certified Advanced Programmer specializing in the analysis of clinical trial data. His clients have included major pharmaceutical corporations, biotech companies, and research organizations.

Josh loves coding and has enjoyed presenting numerous times at SAS® Global Forum, PharmaSUG, and various regional and local SAS® User Group meetings. He holds a bachelor's degree in mathematics and computer science, and a master's degree in statistics from Colorado State University.




Powered by Create your own unique website with customizable templates.