The Variables Menu

Properties
Choosing this menu item displays a dialog box that enables you to change most properties for the selected variable.
Interval/Nominal
Choosing these menu items changes the measure level of the selected numeric variable. A character variable cannot be interval.
Label
Choosing this menu item makes the selected variable the label variable for plots.
Frequency
Choosing this menu item makes the selected variable the frequency variable for analyses and plots that support a frequency variable. Only numeric variables can have a Frequency role.
Weight
Choosing this menu item makes the selected variable the weight variable for analyses and plots that support a weight variable. Only numeric variables can have a Weight role.
Ordering
Choosing this menu item specifies how nominal variables are ordered. This affects the way that a variable is sorted and the order of categories in plots. If a variable has missing values, they are always ordered first. You can order a variable in the following ways:
Standard
This options specifies that categories are arranged in Unicode order by their unformatted values. In Unicode order, numerals precede uppercase letters, which precede lowercase letters.
by Frequency
This options specifies that categories are arranged according to the descending frequency count of formatted values in each category.
by Format
This options specifies that categories are arranged in Unicode order by their formatted values.
by Data
This options specifies that categories are arranged according to the data order of formatted values. The data order is determined by traversing the values of a variable, starting from the first observation. The first (nonmissing) value you encounter is ordered first, the next unique (nonmissing) value of the variable is ordered second, and so on. Sorting the data table does not affect this ordering; it is based on the original order of observations.
by Frequency (unformatted)
This options specifies that categories are arranged according to the descending frequency count of unformatted values in each category.
by Data (unformatted)
This option specifies that categories are arranged according to the data order of unformatted values. Sorting the data table does not affect this ordering; it is based on the original order of observations.
Custom
This option specifies that this variable was ordered by calling the method DataObject.SetVarValueOrder.
Sort
Choosing this menu item displays a dialog box that you can use to sort observations. If any variables are selected, those variables are added to the Variables to sort by list and are assigned a default sorting criterion (either A for ascending or D for descending). The observations are sorted when you click OK.
Variables in data set
This list displays all the variables that are not yet involved in sorting. If you select a variable in this list you can then click Add to assign the variable to the Variables to sort by list.
Variables to sort by

This list displays all the variables that are currently involved in sorting. The first variable in the list is the primary sort variable, meaning that your observations will be sorted by that variable in either ascending (A) or descending (D) order.

The second variable in the Variables to sort by list will be used to break ties when several observations all have the same value of the first variable. Subsequent variables will be used to break ties among observations that have the same values for all preceding variables in the Variables to sort by list.

If you select a variable in the Variables to sort by list, you can

  • Change the variable's ascending/descending sort status either by double-clicking the variable's name or by using the Set Ascending and Set Descending buttons.
  • Move the variable up or down in the Variables to sort by list, thus making the variable more or less important in the sort.
  • Remove the variable from the Variables to sort by list by clicking Remove.
New Variable
Choosing this item displays a dialog box for the creation of a new variable. You are prompted to enter a name for the variable, and to specify whether the variable is a numeric or character variable. Variable names must comply with SAS variable naming guidelines.
Delete
This item deletes all selected variables.
Display Name/Display Label
Choosing these menu items toggles whether the column heading displays the name of variables or displays their labels.
Hide
Choosing this menu item hides the selected variables. The variables can be displayed at a later time by selecting Show All. Hidden variables cannot be selected.
Show All
This menu item is only available if one or more variables are hidden. Choosing this item results in the data table displaying all variables.
Invert Selection
Choosing this menu item changes the set of selected variables. Unselected variables become selected, while selected variables become unselected.
Generate _OBSTAT_ Variable
Choosing this menu item creates a variable called _OBSTAT_. The _OBSTAT_ variable is a character variable of length 20. It was introduced in SAS/INSIGHT software as a way to capture the state of observations, including the color and shape of markers and whether an observation is selected.