From the course: SAS Programming for R Users, Part 1

Unlock this course with a free trial

Join today to access over 22,600 courses taught by industry experts.

Enhanced reporting: Labels and formats

Enhanced reporting: Labels and formats - SAS Tutorial

From the course: SAS Programming for R Users, Part 1

Enhanced reporting: Labels and formats

- [Instructor] In this section, I want to apply labels and formats to my datasets and results so I can alter the presentation of the data table or report. So for example, maybe I want to change the label of FN and LN to First Name and Last Name. Maybe I want to change the observation display of the job variable from SR and SM to sales Rep and Sales Manager. And finally we'll look at how to apply a format to a variable like Salary so I can tack on a dollar sign. We'll look at SAS date formats as well. So how can I display a date in a logical format so I can actually read it? So the Label statement is used to change the display of the column variables. So in the Label statement, I'll specify my variable name. In this case, FN. And I'll set it equal to a new display. In this case, First Name. Same as LN equal to Last Name. And again, this only changes the display of the columns. The variable names are kept the same as FN and LN. And in the print procedure, when you're using the label…

Contents