SAS OnlineTutor HomeFAQ PageSuggested Learning PathsContents+Searchback||next

Creating Tabular Reports
Specifying Variables


Class Variables

Class variables

  • can be character or numeric.
  • classify data into groups or categories.
  • have only a few distinct values, in most cases. (PROC TABULATE prints each value of a class variable.)

It makes sense to compute a frequency count on a class variable. For example, you can use a variable such as Department as a class variable to find the number of employees in each department. Or you can specify Sex as a class variable to find the number of females and males.

PctInsured (percentage insured) and Company (insurance company) below are class variables. Notice that their values form headings for the table.


  PctInsured
50 60 80 100
N N N N
Company 1.00 2.00 1.00 2.00
Parnassus
Reliable 1.00 2.00 1.00 1.00
Ruritan 1.00 1.00 2.00 1.00
USA Inc. 2.00 1.00 1.00 1.00



back||next


Copyright © 2002 SAS Institute Inc., Cary, NC, USA. All rights reserved.

Terms of Use & Legal Information | Privacy Statement