Recoding Values - Example

The following set of (two) recoding conditions convert (translate) all cases (observations) in the currently highlighted variable into 1 (if the value of variable number 1 for those cases is positive or zero) or into -1 (if the value of variable number 1 for those cases is negative).

  Include If: New Value:
Category 1 v1>=0 1
Category 2 v1<0 -1
Note: Recoding conditions might be defined such that the new values of the current variable do not depend on the old values of that variable, but only on values of some other variables in the data set. In other words, the currently highlighted variable does not have to be included in the text of the recoding conditions; for instance in this example, the currently highlighted variable could be variable number 3, and its new (recoded) values depend only on values of variable number 1. If the currently highlighted variable was variable number 1, then its values would be translated into new ones (positive values would become 1 and negative values would become -1). See also: Recoding Values.