Reclassifying the Data
- Using a Variable File source node, connect to the dataset
drug_long_name in the Demos folder.
Figure 1. Sample stream showing string reclassification for binomial logistic regression - Add a Type node to the Source node and select Cholesterol_long as the target.
- Add a Logistic Regression node to the Type node.
- In the Logistic Regression node, click the Model tab and select the
Binomial procedure.
Figure 2. Long string details in the "Cholesterol_long" field - When you execute the Logistic Regression node in
reclassify_strings.str, an error message is displayed warning that the
Cholesterol_long string values are too long.
If you encounter this type of error message, follow the procedure explained in the rest of this example to modify your data.
Figure 3. Error message displayed when executing the binomial logistic regression node - Add a Reclassify node to the Type node.
- In the Reclassify field, select Cholesterol_long.
- Type Cholesterol as the new field name.
- Click the Get button to add the Cholesterol_long values to the original value column.
- In the new value column, type High next to the
original value of High level of cholesterol and Normal
next to the original value of Normal level of cholesterol.
Figure 4. Reclassifying the long strings - Add a Filter node to the Reclassify node.
- In the Filter column, click to remove
Cholesterol_long.
Figure 5. Filtering the "Cholesterol_long" field from the data - Add a Type node to the Filter node and select
Cholesterol as the target.
Figure 6. Short string details in the "Cholesterol" field - Add a Logistic Node to the Type node.
- In the Logistic node, click the Model tab and select the Binomial procedure.
- You can now execute the Binomial Logistic node and generate a model without displaying an error message.

This example only shows part of a stream. If you require further information about the types of streams in which you may need to reclassify long strings, the following examples are available:
- Auto Classifier node. See the topic Modeling Customer Response (Auto Classifier) for more information.
- Binomial Logistic Regression node. See the topic Telecommunications Churn (Binomial Logistic Regression) for more information.
More information on how to use IBM® SPSS® Modeler, such as a user's guide, node reference, and algorithms guide, are available from the \Documentation directory of the installation disk.