The salary
variable ranges from 67.5 to 2,460 (measured in thousands of dollars). Since the variation of salaries is much greater for
the higher salaries, it is appropriate to apply a logarithmic transformation to the salaries before fitting the model. The
following steps use the Variable Transformation Wizard to transform the salary variable. (This wizard is described in further
detail in Chapter 32: Variable Transformations.)
Open the Baseball
data set.
Select
→ from the main menu.The Variable Transformation Wizard in Figure 21.1 appears.
Select the
transformation from the list.
Figure 21.1: Selecting a Log10 Transformation
Click
.The wizard displays the page shown in Figure 21.2.
Figure 21.2: Selecting a Variable and Parameters
Scroll to the end of the variable list. Select the salary
variable, and click .
The parameter a is an offset that is useful if your variable contains nonpositive values. For these data, you can accept the default value of 0.
Click
.Because there are missing values for the salary
variable, a warning message appears (Figure 21.3) that informs you that the transformed values for these observations are set to missing values.
Figure 21.3: A Warning Message
Click
to dismiss the warning message.SAS/IML Studio adds the new variable, Log10_salary
, as the last variable in the data set.