Select menu: Spread | Factor | Reorder Levels
Use this to change the association between the labels or levels of a factor and the underlying ordinal values. Any analysis or calculation involving a factor will use the current factor level/label ordering. For example, if a table is calculated using one classifying factor then the first level/label of the factor will be used for the first row of the table, and so on. By default, when a factor is created within Genstat the levels will be ordered numerically, and labels alphabetically. However, the ordering of the factor levels or labels can easily be changed using this dialog.
- From the menu select Spread | Factor | Reorder Levels.
Dropdown list of the factors available within the spreadsheet.
Factor level/labels list
Displays the order of the labels/labels in the factor. Items within the list can be reordered using the buttons alongside the list.
|OK||Change the order of the factor and close the dialog.|
|Apply||Change the order of the factor and leave the dialog open to select another factor to change.|
|Cancel||Close dialog without making any changes.|
|Help||Opens the Help for this dialog.|
|Top||Move the selected item to the top of the list.|
|Up||Move the selected item up one place in the list.|
|Down||Move the selected item down one place in the list.|
|Bottom||Move the selected item to the bottom of the list.|
|Sort||Opens a dialog with additional facilities for reordering the levels/labels using different sorting operations.|
The up and down arrows, Page Up/Down, and Home/End keys will move the selection in the list in the usual manner. When the Ctrl or Shift keys are depressed with the above cursor keys, the selected item will be moved within the list. The Esc key or Ctrl+F4 keys will cancel, and the Enter will activate the OK button. The buttons may also be activated by using the Alt+underlined letter.
Four ordered categories are placed alphabetically into a factor:
Another possible ordering for the labels would be to have Low, Medium then High. To change to this ordering the label Zero can be moved to the start of the list by selecting Zero and clicking the Top button. The label High can be moved to the bottom of the list by selecting High and clicking the Bottom button. This will now give the ordering shown below:
Clicking OK will then make these changes in the spreadsheet.
- Understanding Factors within a Spreadsheet
- Edit Factor Levels and Labels
- Recode a Column
- Spreadsheet Factor Menu
- Sort Label/Level Order within a Factor Column
- Select Summary Statistic to Sort Levels on
The FACSORT procedure can be used within the command language to provide reorder the levels of a factor.