Presentation on theme: "Best subsets regression"— Presentation transcript:
1Best subsets regression Model selectionBest subsets regression
2Statement of problemA common problem is that there is a large set of candidate predictor variables.Goal is to choose a small subset from the larger set so that the resulting regression model is simple, yet have good predictive ability.
3Example: Cement dataResponse y: heat evolved in calories during hardening of cement on a per gram basisPredictor x1: % of tricalcium aluminatePredictor x2: % of tricalcium silicatePredictor x3: % of tetracalcium alumino ferritePredictor x4: % of dicalcium silicate
5Two basic methods of selecting predictors Stepwise regression: Enter and remove predictors, in a stepwise manner, until no justifiable reason to enter or remove more.Best subsets regression: Select the subset of predictors that do the best at meeting some well-defined objective criterion.
7Why best subsets regression? If there are p-1 possible predictors, then there are 2p-1 possible regression models containing the predictors.For example, 10 predictors yields 210 = 1024 possible regression models.A best subsets algorithm determines the best subsets of each size, so that choice of the final model can be made by researcher.
8What is used to judge “best”? R-squaredAdjusted R-squaredMSE (or S = square root of MSE)Mallow’s Cp
9R-squaredUse the R-squared values to find the point where adding more predictors is not worthwhile because it leads to a very small increase in R-squared.
10Adjusted R-squared or MSE Adjusted R-squared increases only if MSE decreases, so adjusted R-squared and MSE provide equivalent information.Find a few subsets for which MSE is smallest (or adjusted R-squared is largest) or so close to the smallest (largest) that adding more predictors is not worthwhile.
11Mallow’s Cp criterionThe goal is to minimize the total standardized mean square error of prediction:which equals:which in English is:
12Mallow’s Cp criterion Mallow’s Cp statistic estimates where: SSEp is the error sum of squares for the fitted (subset) regression model with p parameters.MSE(X1,…, Xp-1) is the MSE of the model containing all p-1 predictors. It is an unbiased estimator of σ2.p is the number of parameters in the (subset) model
13Facts about Mallow’s Cp Subset models with small Cp values have a small total standardized MSE of prediction.When the Cp value is …near p, the bias is small (next to none),much greater than p, the bias is substantial,below p, it is due to sampling error; interpret as no bias.For the largest model with all possible predictors, Cp= p (always).
14Using the Cp criterion So, identify subsets of predictors for which: the Cp value is smallest, andthe Cp value is near p (if possible)In general, though, don’t always choose the largest model just because it yields Cp= p.
15Best Subsets Regression: y versus x1, x2, x3, x4 Response is yx x x xVars R-Sq R-Sq(adj) C-p SXXX XX XX X XX X XX X X X
16Stepwise Regression: y versus x1, x2, x3, x4 Alpha-to-Enter: Alpha-to-Remove: 0.15Response is y on 4 predictors, with N = 13StepConstantxT-ValueP-ValuexT-ValueP-ValuexT-ValueP-ValueSR-SqR-Sq(adj)C-p
18Best Subsets Regression: PIQ versus MRI, Height, Weight Response is PIQH We ei iM g gR h hVars R-Sq R-Sq(adj) C-p S I t tXXX XX XX X X
19Stepwise Regression: PIQ versus MRI, Height, Weight Alpha-to-Enter: Alpha-to-Remove: 0.15Response is PIQ on 3 predictors, with N = 38StepConstantMRIT-ValueP-ValueHeightT-ValueP-ValueSR-SqR-Sq(adj)C-p
21Best Subsets Regression: BP versus Age, Weight, ... Response is BPDuW r Se a P ti t u rA g B i l eg h S o s sVars R-Sq R-Sq(adj) C-p S e t A n e sXXX XX XX X XX X XX X X XX X X XX X X X XX X X X XX X X X X X
22Stepwise Regression: BP versus Age, Weight, BSA, Duration, Pulse, Stress Alpha-to-Enter: Alpha-to-Remove: 0.15Response is BP on 6 predictors, with N = 20StepConstantWeightT-ValueP-ValueAgeT-ValueP-ValueBSAT-ValueP-ValueSR-SqR-Sq(adj)C-p
23Best subsets regression Stat >> Regression >> Best subsets …Specify response and all possible predictors.If desired, specify predictors that must be included in every model. (Researcher’s knowledge!)Select OK. Results appear in session window.