Examples (MLP command)

Basic specification with default neural network settings

MLP DepVar BY A B C WITH X Y Z. 
  • The MLP procedure treats DepVar as the dependent variable.
  • Predictors A, B, and C are factors, and X, Y, and Z are covariates.
  • By default, covariates are standardized before training. Also, the active dataset is partitioned into training and testing data samples, with 70% going to the training data and 30% to the testing data sample.
  • Automatic architecture selection is used to find the “best” neural network architecture.
  • User-missing values are excluded and default output is displayed.

User-specified neural network with two hidden layers

MLP DepVar BY A B C WITH X Y Z
  /PARTITION
     TRAINING=100 TESTING=0
  /ARCHITECTURE
     AUTOMATIC=NO
     HIDDENLAYERS=2 (NUMUNITS=25,10)
     OUTPUTFUNCTION=SIGMOID.
  • The MLP procedure treats DepVar as the dependent variable. Predictors A, B, and C are factors, and X, Y, and Z are covariates.
  • By default, covariates are standardized before training. The PARTITION subcommand overrides the default partitioning of the active dataset into training and testing data and treats all cases as training data.
  • The ARCHITECTURE subcommand turns off automatic architecture selection (AUTOMATIC = NO) and specifies a neural network with two hidden layers. There are 25 hidden units in the first hidden layer and 10 hidden units in the second hidden layer. The sigmoid activation function is used for units in the output layer.
  • User-missing values are excluded and default output is displayed.