Workflow: Predicting a binary variable with the MLP block
IanBD
Altair Employee
The MLP block enables you to apply a multilayer perceptron (MLP) neural network model to a dataset.
The following demonstrates how to use the MLP block to make predictions on a dependent variable from an input dataset basketball_shots.csv (containing observations describing a basketball shot in a professional game and the person taking the shot) based on other independent variables from the input dataset:
- Import the basketball_shots.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 an MLP block onto the Workflow canvas.
- Click the Output port of the basketball_shots dataset block and drag a connection towards the Input port of the MLP block.
- Double-click the MLP block to display the Multilayer Perceptron view and the MLP Preferences dialog box.
- In the MLP Preferences dialog box:
- In the Train drop-down list, select Working Dataset.
- Click Variable Selection to display the Variable Selection panel:
- in the Dependent variable drop-down list, select Score.
- In the Unselected Independent Variables list, press and hold CTRL and select the angle, distance_feet, height, position, and weight variables.
- Click Select to move the specified variables to the Selected Independent Variables list.
- Click Optimiser, and in the Optimiser drop-down list select ADAM.
- Click Stopping Criteria, and in the Max training time (s) enter 10
- Click OK to save the configuration and close the MLP Preferences dialog box.
- In the Multilayer Perceptron view, click Train to train the MLP model.
- Close the Multilayer Perceptron view and save the configuration when prompted.
A green execution status is displayed in the Output port of the MLP block. The MLP block output can be used with a Score Block in order to make predictions on a dataset.
0