The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information....



VarInflatFactor


Unit: SDL_math2
Class: none
Declaration: function VarInflatFactor (Data: TMatrix; VarList: TIntArray; var VIFs: TDoubleArray; Feedback: TOnPercentDoneEvent): integer;

The function VarInflatFactor calculates the variance inflation factors (VIF) of a set of variables of the dataset Data, assuming the matrix Data is organized in a way that the matrix columns are the variables and the rows are the objects. The array VarList specifies the indices of the variables to be processed.

The calculated VIFs are returned in the array VIFs in the order of the list of indices in VarList. The size of the array VIFs is automatically adjusted to the length of the array VarList. Please note that the returned VIF values are limited to the range 1..1000000. VIFs greater than 1000000 are automatically limited to 1000000 (thus a value of 1000000 can be interpreted as "infinite", indicating perfect collinearity).

The parameter Feedback allows to provide feedback during lengthy calculations. Setting the parameter Feedback to nil switches off any feedback.

The function returns the following error codes:

 0 ... everything is OK
-1 ... VarList contains an invalid column index (valid range: 1..Data.NrOfColumns)


Last Update: 2023-Dec-10