Creating Derived Variables on the Fly
JMP software provides users with the ability to derive new variables through the formula editor window. However, it is also possible to create variables on the fly, making it easier for users to explore their data from every perspective while remaining in the analysis flow. These derived variables can be temporary or permanently stored.
The following example uses data that contains information on a collection of demographic and health related factors. The data is being explored through the Graph Builder. While exploring the data the analyst decides to calculate an individuals BMI using the data collected on the individuals height and weight.
The analyst needs to create the variable BMI using the following formula:
BMI = Weight/(Height 2).
Using a step by step approach, the calculation of the derived variable is shown.
The first step, is to create a variable that will contain the value of Height 2. By selecting the variable in the variable list and right clicking, a number of options which includes Transform, Aggregate and Row can be selected. These options group related functions that are used to create new variables. The Transform option is selected and a list of transformation functions is then presented. The Square option is selected.
Within the variables list, the new temporary height2 variable is presented.
The next step, is to divide height2 by the variable weight.
Selecting both variables and right clicking, a further option Combine is given. This option is selected along with the function Ratio.
A temporary variable is created. To rename the temporary variable, right click and select the option Rename from the options menu.
The following window opens. The new variable name is entered into the cell and OK is selected.
New variables created are temporary, and are not added to the data table. To make any derived variable permanent, right click on the derived variable (BMI) and select Add to Data Table.
The variable is now permanently stored in the data table. A sample of which is shown below: