The PHSELECT Procedure

Example 19.1 Model Selection

The following statements examine the same data as in the section Getting Started: PHSELECT Procedure, but they request model selection via the forward selection technique. Effects that provide the best improvement to the selection criterion, the Schwartz Bayesian criterion (SBC), are added until no more effects can improve the selection criterion. The DETAILS=ALL option in the SELECTION statement produces all tables that are related to model selection. The PLOTS=ALL option produces graphics to help you interpret the selection process. ODS Graphics must be enabled before you can request plots. (For more information about ODS Graphics, see the section ODS Graphics.)

ods graphics on;

proc phselect data=mycas.getStarted;
   class C1-C3;
   model Time*Status(0) = C1-C3 X1-X4;
   selection method=forward(stop=sbc select=sbc) details=all plots=all;
run;

The model selection tables are shown in Output 19.1.1 through Output 19.1.3. Results from the selected model are shown in Output 19.1.4 and Output 19.1.5. Selection graphics that the PLOTS= option produces are displayed in Output 19.1.6 and Output 19.1.7.

The "Selection Information" table in Output 19.1.1 summarizes the settings for the model selection. Effects are added to the model only if they produce a significant improvement, which is determined by comparing their SBC values. The forward selection stops three steps after the smallest SBC is obtained or when all effects have been added to the model.

Output 19.1.1: Selection Information

The PHSELECT Procedure

Selection Information
DescriptionValue
Selection MethodForward
Select CriterionSBC
Stop CriterionSBC
Effect Hierarchy EnforcedNone
Stop Horizon3


For each step of the selection process, the DETAILS=ALL option displays the candidate effects for entering the model along with their SELECT= criterion. Output 19.1.2 displays this table for the first step; the other steps are not shown here.

Output 19.1.2: Step1 Entry Candidates

The PHSELECT Procedure
 
Forward Selection: Step 1
Effect Entered: X1

Entry Candidates
RankEffectSBC
1X1536.7462
2X4539.8497
3C2544.9948
4X3548.2815
5X2548.9490
6C3549.1132
7C1551.8649


The DETAILS=ALL option also displays the dimensions, fit statistics, and parameter estimates at each step of the selection process; these details are not shown here.

When the selection procedure is complete, the "Selection Summary" table in Output 19.1.3 shows the effects that were added to the model and the value of their selection criterion (and the choose and stop criteria, if they are specified). In step 1, effect X1 made the most significant contribution to the model among the candidate effects, according to the SBC statistic. In step 2, X4 made the most significant contribution when an effect was added to a model that contains X1. In the three subsequent steps, no effect could be added to the model that would reduce the SBC value, so variable selection stopped because the stop horizon (see Output 19.1.1) indicates that at most three steps beyond the minimum SBC value are taken.

In Output 19.1.3, the "Selection Summary" table is followed by three small tables that summarize why the process stopped and which model is selected.

Output 19.1.3: Selection Summary Information

The PHSELECT Procedure
 
Selection Details

Selection Summary
StepEffect
Entered
Number
Effects In
SBC
1X11536.7462
2X42535.1652*
3C13538.2917
4X24539.2661
5X35542.4842
* Optimal Value Of Criterion

Selection stopped at a local minimum of the SBC criterion.

The model at step 2 is selected.

Selected Effects:X1 X4


Output 19.1.4 displays information about the selected model. Notice that the –2 log-likelihood value in the "Fit Statistics" table is larger than the value for the full model in Figure 7. This is expected because the selected model contains only a subset of the parameters. Because the selected model is more parsimonious than the full model, the discrepancy between the –2 log likelihood and the information criteria is less severe than that shown in Figure 7 in the "Getting Started" example.

Output 19.1.4: Dimensions and Fit Statistics

The PHSELECT Procedure
 
Selected Model

Dimensions
Number of Effects2
Max Effect Columns1
Columns in Design2
Rank of Design2

Fit Statistics
-2 Log Likelihood526.74445
AIC (smaller is better)530.74445
AICC (smaller is better)530.91346
SBC (smaller is better)535.35258


The parameter estimates of the selected model are shown in Output 19.1.5. Notice that the effects are listed in the "Parameter Estimates" table in the order in which they are specified in the MODEL statement and not necessarily in the order in which they are added to the model.

Output 19.1.5: Parameter Estimates

Parameter Estimates
ParameterDFEstimateStandard
Error
Chi-SquarePr > ChiSq
X111.6053060.5138119.76130.0018
X41-0.1233040.0466976.97230.0083


The coefficient panel in Output 19.1.6 enables you to visualize the selection process. In this plot, standardized coefficients of all the effects that are selected at some step of the stepwise method are plotted as a function of the step number. This enables you to assess the relative importance of the effects that are selected at any step of the selection process and to know when effects entered the model. The lower plot in the panel shows how the criterion that is used to choose the selected model changes as effects enter or leave the model.

Output 19.1.6: Coefficient Progression

Coefficient Progression


The criterion panel in Output 19.1.7 provides a graphical view of the progression of the fit criteria as the selection process evolves. Notice at Step 2 that the SBC value seems to be at its minimum. Because the stop horizon value is 3 (see Output 19.1.1), three more steps are taken to determine if Step 2 is a global optimum. None of these three subsequent steps have a smaller SBC value than in Step 2, so the global optimum is at step 2.

Output 19.1.7: Criterion Panel

Criterion Panel


Last updated: September 13, 2022