Ridge trace plot

Produces a ridge trace plot and a plot of RSS VS K for data in Y and predictors formed into the M1 matrix. M1 and Y should be in "correlation form". These plots are useful data analytic tools for ridge regression.

Produces a ridge trace plot and a plot of RSS VS K for data in Y and predictors formed into the M1 matrix. M1 and Y should be in "correlation form". These plots are useful data analytic tools for ridge regression.

Download the Macro

Be sure that Minitab knows where to find your downloaded macro. Choose File > Options > General. Under Macro location browse to the location where you save macro files.

Important

If you use an older web browser, when you click the Download button, the file may open in Quicktime, which shares the .mac file extension with Minitab macros. To save the macro, right-click the Download button and choose Save target as.

Required Inputs

  • A column of responses
  • Column of K values for ridge trace
  • Number of predictor columns (excluding constant term)
  • Matrix of predictor variables centered and scaled

Running the Macro

To run the macro, choose View > Command Line/History and type:

%RTP

Click Run.

More Information

This macro utilizes the following columns, constants, and matrices for "scratch" storage. Be sure these locations are empty, or edit the code to specify different storage locations.

  • C45 C46 C47
  • K2 K3 K5 K6
  • M2 M3 M4 M5

Reference

D.W. Marquardt & R.D. Snee, "Ridge Regression in Practice" The American Statistician, VOL. 29, NO. 1.