Recode a Variable

SAS/LAB software provides facilities for creating a new variable that is a recoding of an existing variable in the same data set. This new variable is added to the current data set.

To create a new variable by recoding an old one, select 'Modify' and then 'Recode a variable' from the File pull-down menu on the main window. The resulting pull-down menu offers the following methods of recoding:

Note that the existing variable is not changed when the new variable is created. You must have write access to the data set to be able to recode variables. The data set must not be a view.