drasys.or.stat.model
Interface LinearRegressionI

All Known Implementing Classes:
LinearRegression, StepwiseLinear, ReverseLinear

public interface LinearRegressionI

The interface implemented by linear regression models.


Method Summary
 int[] allVariables()
          A convenience method that returns an array that selects all of the independent variables.
 VectorI getCoefficients()
          Returns the selected variable coefficients.
 double getEnteringThreshold()
          Returns the p-value threshold used to select entering variables.
 int[] getEnteringVariables()
          Returns the internal array describing entering variable set.
 double getExitingThreshold()
          Returns the p-value threshold used to select exiting variables.
 double getF()
          Returns the 'F' statistic for the currrent model.
 double getFPV()
          Returns the one-sided p-value for the current 'F' statistic.
 GeneralLinearModelI getGLM()
          Returns the underlying general linear model used for solving the regression.
 VectorI getLowerBounds(double confidenceLevel)
          Returns the selected variable lower bounds.
 int[] getRequiredVariables()
          Returns the internal array describing required variable set.
 int[] getSelectedVariables()
          Returns the internal array describing current variable set.
 VectorI getT()
          Returns the 'T' statistics for the selected variables.
 VectorI getTPV()
          Returns the two-sided p-values for the 'T' statistics of the selected variables.
 double getTStatistic(double pValue)
          Returns the the 'T' statistic for a given p-value;
 VectorI getUpperBounds(double confidenceLevel)
          Returns the selected variable upper bounds.
 void setEnteringThreshold(double pValue)
          Sets the p-value threshold used to select entering variables.
 void setEnteringVariables(int[] variables)
          Selects the set of variables allowed to enter the model.
 void setExitingThreshold(double pValue)
          Sets the p-value threshold used to select exiting variables.
 void setRequiredVarables(int[] variables)
          Selects the set of variables that are forced into the final model.
 void setSelectedVariables(int[] variables)
          Selects the current variable set and and solves the model.
 int solve()
          Solve for the significant variables and coefficients.
 

Method Detail

solve

public int solve()
Solve for the significant variables and coefficients. Returns the number of independent variables selected in the final model.

getGLM

public GeneralLinearModelI getGLM()
Returns the underlying general linear model used for solving the regression. The ANOVA statistics can be obtained directly from the GLM.

allVariables

public int[] allVariables()
A convenience method that returns an array that selects all of the independent variables. Returns - {0,1,2,...,n-1}.

setEnteringVariables

public void setEnteringVariables(int[] variables)
Selects the set of variables allowed to enter the model. The default setting is {0,1,2,...,n-1} which allows all variables to enter.

setRequiredVarables

public void setRequiredVarables(int[] variables)
Selects the set of variables that are forced into the final model. The default setting is {} which does not force any variables into the model.

setEnteringThreshold

public void setEnteringThreshold(double pValue)
Sets the p-value threshold used to select entering variables. The default value is '0.05'.

getEnteringThreshold

public double getEnteringThreshold()
Returns the p-value threshold used to select entering variables.

setExitingThreshold

public void setExitingThreshold(double pValue)
Sets the p-value threshold used to select exiting variables. The default value is '0.05'.

getExitingThreshold

public double getExitingThreshold()
Returns the p-value threshold used to select exiting variables.

setSelectedVariables

public void setSelectedVariables(int[] variables)
Selects the current variable set and and solves the model. Immediately after construction all the variables are selected and the model is solved. The subclass search algorithms use this method to test diferent variable sets for each iteration.

getF

public double getF()
Returns the 'F' statistic for the currrent model.

getFPV

public double getFPV()
Returns the one-sided p-value for the current 'F' statistic.

getCoefficients

public VectorI getCoefficients()
Returns the selected variable coefficients. The coefficient at index 'n' corresponds to the column indexed by 'selection[n]'. If a constant intercept term is included, its value will be in the last element.

getLowerBounds

public VectorI getLowerBounds(double confidenceLevel)
Returns the selected variable lower bounds. The coefficient at index 'n' corresponds to the column indexed by 'selection[n]'. If a constant intercept term is included, its value will be in the last element.

getUpperBounds

public VectorI getUpperBounds(double confidenceLevel)
Returns the selected variable upper bounds. The coefficient at index 'n' corresponds to the column indexed by 'selection[n]'. If a constant intercept term is included, its value will be in the last element.

getT

public VectorI getT()
Returns the 'T' statistics for the selected variables. The statistic at index 'n' corresponds to the column indexed by 'selection[n]'.

getTPV

public VectorI getTPV()
Returns the two-sided p-values for the 'T' statistics of the selected variables. The p-value at index 'n' corresponds to the column indexed by 'selection[n]'.

getTStatistic

public double getTStatistic(double pValue)
Returns the the 'T' statistic for a given p-value;

getSelectedVariables

public int[] getSelectedVariables()
Returns the internal array describing current variable set. This array should not be directly modified.

getEnteringVariables

public int[] getEnteringVariables()
Returns the internal array describing entering variable set. This array should not be directly modified.

getRequiredVariables

public int[] getRequiredVariables()
Returns the internal array describing required variable set. This array should not be directly modified.


Copyright(C)1997-2000 by DRA Systems all rights reserved. OpsResearch.com