The HPREDUCE Procedure
Unsupervised Variable Selection with the HPREDUCE Procedure
The following statements use PROC HPREDUCE for unsupervised variable selection. The statements specify that the technique used for variable selection is variance analysis. The maximum number of variables to select is 5, and the maximum percentage of the total variance to explain is 95%. The procedure stops when either of two conditions is satisfied.
proc hpreduce data=getstarted technique=VarianceAnalysis;
class C;
reduce unsupervised C x1-x10 / maxeffects=5 varexp=0.95;
performance details;
run;
The output from this analysis is presented in Figure 1 through Figure 6.
Figure 1 shows the "Performance Information" table, which indicates that the procedure ran locally with four threads.
Figure 1: Performance Information
| Performance Information | |
|---|---|
| Execution Mode | Single-Machine |
| Number of Threads | 16 |
Figure 2 shows the "Data Access Information" table, which provides the information about the data sets that the HPREDUCE procedure has accessed and generated.
Figure 2: Data Access Information
| Data Access Information | |||
|---|---|---|---|
| Data | Engine | Role | Path |
| WORK.GETSTARTED | V9 | Input | On Client |
Figure 3 displays the "Model Information" and "Number of Observations" tables. The "Model Information" table shows that the HPREDUCE procedure is used for unsupervised variable selection. The CLASS variable C is parameterized in the general linear model (GLM) parameterization, which is the default. The total number of variables is 11. The technique used for variable selection is variance analysis. The maximum number of variables to select is 5, and the maximum percentage of the total variance to explain is 95%. The "Number of Observations" table shows that all 100 observations in the data set are used in the analysis.
Figure 3: Model Information and Number of Observations
| Model Information | |
|---|---|
| Data Source | GETSTARTED |
| Model Type | Unsupervised |
| Class Parameterization | GLM |
| Selection Technique | Variance Analysis |
| Number of Variables | 11 |
| Number of Variables to Select | 5 |
| Variance to Explain | 0.95 |
| Number of Observations Read | 100 |
|---|---|
| Number of Observations Used | 100 |
Figure 4 shows the "Class Level Information" table, which indicates that the CLASS variable C has 10 unique formatted levels.
Figure 4: Class Level Information and Response Profile
| Class Level Information | ||
|---|---|---|
| Class | Levels | Values |
| C | 10 | A B C D E F G H I J |
Figure 5 shows the "Selection Summary" and "Selected Variables" tables. The "Selection Summary" table shows which variable (or level for CLASS variables) is selected in each step, in addition to the total variance that is explained by the variables selected so far. The "Selected Variables" table presents all the selected variables and their corresponding variable types.
Figure 5: Selection Summary and Selected Variables
| Selection Summary | ||||||||
|---|---|---|---|---|---|---|---|---|
| Iteration | Selected Effect | Level | Proportion of Variance Explained | SSE | MSE | AIC | AICC | BIC |
| 1 | x3 | - | 0.0681 | 18.6380 | 0.1883 | 7.1052 | 27.2163 | 2.9713 |
| 2 | x7 | - | 0.1326 | 17.3484 | 0.1770 | 6.9935 | 26.0940 | 2.9456 |
| 3 | x10 | - | 0.1933 | 16.1341 | 0.1663 | 6.8609 | 24.9455 | 2.9191 |
| 4 | C | I | 0.2529 | 14.9423 | 0.1556 | 6.7042 | 23.7675 | 2.8884 |
| 5 | C | F | 0.3120 | 13.7607 | 0.1448 | 6.5218 | 22.5585 | 2.8521 |
| 6 | C | J | 0.3690 | 12.6210 | 0.1343 | 6.3154 | 21.3202 | 2.8117 |
| 7 | C | B | 0.4257 | 11.4856 | 0.1235 | 6.0811 | 20.0487 | 2.7635 |
| 8 | C | G | 0.4813 | 10.3749 | 0.1128 | 5.8194 | 18.7444 | 2.7078 |
| 9 | C | D | 0.5351 | 9.2980 | 0.1022 | 5.5298 | 17.4070 | 2.6443 |
| 10 | C | H | 0.5889 | 8.2218 | 0.0914 | 5.2068 | 16.0308 | 2.5673 |
| 11 | C | A | 0.6407 | 7.1867 | 0.0807 | 4.8522 | 14.6178 | 2.4788 |
| 12 | x5 | - | 0.6916 | 6.1678 | 0.0701 | 4.4593 | 13.1611 | 2.3720 |
| Selected Variables | ||
|---|---|---|
| Number | Selected Variable | Variable Type |
| 1 | x3 | INTERVAL |
| 2 | x7 | INTERVAL |
| 3 | x10 | INTERVAL |
| 4 | C | CLASS |
| 5 | x5 | INTERVAL |
Figure 6 shows the "Procedure Task Timing" table, which provides details about how much time is used by each processing step.
Figure 6: Procedure Task Timing
| Procedure Task Timing | ||
|---|---|---|
| Task | Seconds | Percent |
| Data Read and Variable levelization | 0.01 | 3.63% |
| Effect Levelization | 0.00 | 0.21% |
| Data Preparation for Discriminant Analysis | 0.00 | 0.00% |
| Cross-product Accumulation | 0.19 | 88.94% |
| Variable Selection | 0.02 | 7.22% |