IMSL C# Numerical Library

SelectionRegression.Compute Method (Double[,], Double[], Double[])

Computes the best weighted multiple linear regression models.

public virtual void Compute(
   double[,] x,
   double[] y,
   double[] weights
);

Parameters

x
A double matrix containing the observations of the candidate (independent) variables.
y
A double array containing the observations of the dependent variable.
weights
A double array containing the weight for each of the observations.

Remarks

The number of columns in x must be equal to the number of variables set in the constructor.

Exceptions

Exception TypeCondition
NoVariablesException is thrown if no variables can enter any model
NegativeWeightException is thrown if a weight is less than zero.
TooManyObsDeletedException is thrown if more observations have been deleted than were originally entered
MoreObsDelThanEnteredException is thrown if more observations are being deleted from the output covariance matrix than were originally entered
DiffObsDeletedException is thrown if different observations are being deleted from the return matrix than were originally entered

See Also

SelectionRegression Class | Imsl.Stat Namespace | SelectionRegression.Compute Overload List