Represents a linear regression model.

Namespace: Extreme.Statistics
Assembly: Extreme.Numerics (Extreme.Numerics)

Syntax

Visual Basic (Declaration)
Public Class SimpleRegressionModel _
	Inherits LinearRegressionModel
C#
public class SimpleRegressionModel : LinearRegressionModel
C++
public ref class SimpleRegressionModel : public LinearRegressionModel

Methods

IconTypeDescription
Compute()
Computes the model.
ComputeModel()
Fits the model to the data.
Contains(GeneralLinearModel)
Returns a value that indicates whether another GeneralLinearModel is nested within this instance.
Equals(Object)
Determines whether the specified Object is equal to the current Object.
Finalize()
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
GetCorrelationMatrix()
Gets the correlation matrix for the independent variables in the model.
GetCovarianceMatrix()
Gets the covariance matrix for the independent variables in the model.
GetDurbinWatsonStatistic()
Gets the Durbin-Watson statistic for the residuals of the regression.
GetHashCode()
Serves as a hash function for a particular type.
GetNormalityOfResidualsTest()
Returns a test to verify that the residuals follow a normal distribution.
GetNormalityOfResidualsTest(TestOfNormality)
Returns a test to verify that the residuals follow a normal distribution.
GetRegressionLine()
Returns the regression line.
GetSumOfSquaresMatrix()
Calculates the sum-of-squares matrix for the VariableCollection.
GetType()
Gets the Type of the current instance.
MemberwiseClone()
Creates a shallow copy of the current Object.
Predict(Double[]())
Predicts the value of the dependent variable based on the specified values of the independent variables.
Predict(Vector)
Predicts the value of the dependent variable based on the specified values of the independent variables.
Predict(Matrix)
Predicts the values of the dependent variable for multiple collectionso of values for the independent variables.
ResetComputation()
Clears all computed model parameters.
SetAnovaModelRow(Int32, String, Double, Double)
Sets the data of a row in the model's AnovaTable.
SetAnovaRow(AnovaRowType, String, Double, Double)
Sets the data of a row in the model's AnovaTable.
ToString()
Returns a String that represents the current Object.

Constructors

IconTypeDescription
SimpleRegressionModelNew(VariableCollection, String, String)
Constructs a new SimpleRegressionModel.
SimpleRegressionModelNew(NumericalVariable, NumericalVariable)
Constructs a new SimpleRegressionModel.
SimpleRegressionModelNew(Double[](), Double[]())
Constructs a new SimpleRegressionModel.
SimpleRegressionModelNew(Vector, Vector)
Constructs a new SimpleRegressionModel.

Properties

IconTypeDescription
AdjustedRSquared
Gets the adjusted R Squared value for the regression.
AnovaTable
Gets the AnovaTable that summarizes the results of this model.
BestFitParameters
Gets a vector containing the values of the regression parameters.
CoefficientOfVariation
Gets the coefficient of variation for the regression.
Computed
Gets a value that indicates whether the regression model has been computed.
DegreesOfFreedom
Gets the total degrees of freedom of the data.
DependentVariable
Gets the dependent variable for the regression model.
DependentVariables
Gets the collection of dependent variables associated with this model.
FStatistic
Gets the F statistic for the regression.
IndependentVariables
Gets the collection of independent variables associated with this model.
InterceptParameterName
Gets or sets the name of the intercept parameter.
NoIntercept
Gets or sets a value that indicates whether to include the intercept or constant term in the regression model.
ObservationMatrix
Gets or sets a Matrix whose rows contain the observations.
Parameters
Gets the collection of parameters associated with this model.
PredictedValues
Gets a vector containing the model's predicted values for the dependent variable.
PValue
Gets the probability corresponding to the F statistic for the regression.
Residuals
Gets a vector containing the residuals of the model.
ResidualSumOfSquares
Gets the sum of squares of the residuals of the model.
RSquared
Gets the R Squared value for the regression.
StandardError
Gets the standard error of the regression.
WeightVector
Gets or sets the weights of the observations in this model.

Remarks

Use the SimpleRegressionModel class to investigate a linear relationship between two variables. The technique used to model such a relationship is called simple linear regression.

SimpleRegressionModel inherits from LinearRegressionModel, but has special constructors that make it easier to create simple regression models. It also defines some members that may be more appropriate for the simple case. For example, the GetRegressionLine() method returns a Line object that represents the resulting regression line.

Inheritance Hierarchy

System.Object
  Extreme.Statistics.GeneralLinearModel
    Extreme.Statistics.LinearRegressionModel
      Extreme.Statistics.SimpleRegressionModel