Skip to content

SAS Example Code

Examples, Tips & Tricks

  • How To’s
  • Functions
  • Statements
  • Formats
  • Macros
  • Data Visualisation
  • About

SAS How To’s

On this page you find an overview of all the “How To’s” of this website.

How To:

  • Add Leading Zeros
  • Append Datasets
  • Avoid Division by Zero
  • Calculate the Average per Group
  • Check if a Dataset is Empty
  • Concatenate Strings
  • Convert Datetime into Date
  • Count the Number of Missing Values
  • Count the Number of Rows
  • Create a Dynamic PROC TRANSPOSE
  • Create an Empty Dataset
  • Create a Dataset Manually
  • Create a Library
  • Create a User-Defined Format
  • Calculate the Cumulative Sum (by Group)
  • Delete Data Sets
  • Delete an Empty Dataset
  • Dynamically Rename Column Names
  • Export Data from SAS to Excel
  • Export Data from SAS as CSV
  • Extract the Last Character from a String
  • Filter Data
  • Find Duplicates
  • Find the Length of a Variable
  • Identify & Remove Empty Columns
  • Insert a Row
  • List Column Names
  • Rank Variables
  • Remove Blanks
  • Remove Duplicates
  • Remove Leading Zeros
  • Remove Macro Variables
  • Rename Variables
  • Replace Missing Values
  • Round Numbers
  • Select Variables with the KEEP & DROP Option
  • Select the First N Rows
  • Select the First Row per Group
  • Select the Last Row per Group
  • Use the Colon Modifier

Search for SAS Code

Popular Posts

  • 5 Simple Ways to Insert a Row into a SAS Dataset
  • Fastest Way to Sort a SAS Dataset
  • How to Rename Variables in SAS
  • How to Convert a Datetime to a SAS Date Format
  • How to Delete an Empty Dataset in SAS

Coursera learner on his laptop featuring 14-day money-back guarantee

Search SAS Code

  • How To’s
  • Functions
  • Statements
  • Formats
  • Macros
  • Data Visualisation
  • About
  • Privacy Policy
WordPress Theme: BlogGrid by TwoPoints.