How do I score new data or classify new observations when using METHOD=NPAR with the DISCRIM procedure?


To classify new observations into groups when using METHOD=NPAR in PROC DISCRIM, you need to use your original training data set as the DATA= input data set. The new observations to be classified must be in a separate data set that you specify with the TESTDATA= option. For example:

proc discrim data=original-data-set testdata=data-to-be-classified;
   class GroupVariable;
   var QuantitativeVar1 QuantitativeVar2 QuantitativeVar3;
   run;

The data-to-be-classified data set contains measurement data on all the same quantitative variables as in the original-data-set. It does not need to contain the class variable.

When using METHOD=NORMAL, you can save the discriminant function coefficients to an OUTSTAT= data set. By using an OUTSTAT= data set as the DATA= input data set in a subsequent run of PROC DISCRIM, the previously computed coefficients can be used to classify new observations. Since the nonparametric approach requires all the training data points in order to classify, there is no equivalent set of discriminant functions that can be obtained. METHOD=NPAR requires that you input the training data and the new data all in the same run of PROC DISCRIM in order to classify the new observations.