Data Management

Using SAS Formats: So Much More Than "M" = "Male"

Date Added: Mar 2010
Format: PDF

Formats in SAS can be used to change the way that a value is displayed. There are numerous formats supplied by SAS for controlling the way dates, times, numbers, currencies and other types of values appear. One can also use PROC FORMAT to build their own formats and create labels for the data values. This paper will look at a number of features of PROC FORMAT: using value ranges, having open-ended ranges (with the LOW and HIGH range values), capturing left-overs (with OTHER), nesting one format inside another, controlling the sort order of the formatted values (with the NOTSORTED option), and allowing a value to fall into more than one range (with the MULTILABEL option).