Workflow: Transforming variables with the WoE transform block
The WoE Transform block enables you to measure the influence of an independent variable on a specified dependent variable, for example to measure risk, and apply variable transformation, for example to transform variables into a finite number of bins and output the results.
The following demonstrates how to use the WoE Transform block to transform variables around discrepancies in the Default variable in an input loan_data.csv dataset (containing observations describing a loan and the person taking the loan out):
- Import the loan_data.csv dataset onto a Workflow canvas using the Text File Import block.
- Expand the Model Training group in the Workflow palette, then click and drag a WoE Transform block onto the Workflow canvas.
- Click the Output port on the loan_data dataset block and drag a connection towards the Input port of the WoE Transform block.
- Double-click the WoE Transform block to display the WoE Transform Editor view.
- In the WoE Transform Editor view:
- In the Dependent variable drop-down list, select Default.
- In the Target Category drop-down list, select 1 (one).
- In the Unselected Variables list, select Income and Housing_Situation.
- Click Select to move the specified to the Selected Variables list.
- In the Selected Variables list, in the Treatment list for Income select Interval; in the Treatment list for Housing_Situationselect Nominal.
- Click the Optimisation tab, click Apply optimal binning to all variables.
- Close the WoE Transform Editor view and save the configuration when prompted.
A green execution status is displayed in the Output port of the WoE Transform block and the output is populated with the dataset plus the new Housing_Situation_WOE and Income_WOE variable transformations. The transformed variables can be used as input for a predictive model for the Default variable.