Click or drag to resize
Accord.NET (logo) PolynomialRegression Class
Polynomial Linear Regression.
Inheritance Hierarchy
SystemObject
  Accord.MachineLearningTransformBaseDouble, Double
    Accord.Statistics.Models.Regression.LinearPolynomialRegression

Namespace:  Accord.Statistics.Models.Regression.Linear
Assembly:  Accord.Statistics (in Accord.Statistics.dll) Version: 3.4.0
Syntax
[SerializableAttribute]
public class PolynomialRegression : TransformBase<double, double>, 
	ILinearRegression, IFormattable
Request Example View Source

The PolynomialRegression type exposes the following members.

Constructors
  NameDescription
Public methodPolynomialRegression
Creates a new Polynomial Linear Regression.
Public methodPolynomialRegression(Int32)
Creates a new Polynomial Linear Regression.
Public methodPolynomialRegression(MultipleLinearRegression)
Creates a new Polynomial Linear Regression.
Top
Properties
  NameDescription
Public propertyCoefficients Obsolete.
Gets the coefficients of the polynomial regression, with the first being the higher-order term and the last the intercept term.
Public propertyDegree
Gets the degree of the polynomial used by the regression.
Public propertyIntercept
Gets or sets the intercept value for the regression.
Public propertyNumberOfInputs
Gets the number of inputs accepted by the model.
(Inherited from TransformBaseTInput, TOutput.)
Public propertyNumberOfOutputs
Gets the number of outputs generated by the model.
(Inherited from TransformBaseTInput, TOutput.)
Public propertyWeights
Gets or sets the linear weights of the regression model. The intercept term is not stored in this vector, but is instead available through the Intercept property.
Top
Methods
  NameDescription
Public methodCoefficientOfDetermination(Double, Double)
Gets the coefficient of determination, as known as R² (r-squared).
Public methodCoefficientOfDetermination(Double, Double, Boolean)
Gets the coefficient of determination, as known as R² (r-squared).
Public methodCompute(Double) Obsolete.
Computes the regressed model output for the given input.
Public methodCompute(Double) Obsolete.
Computes the regressed model output for the given inputs.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodStatic memberFromData
Creates a new polynomial regression directly from data points.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodRegress Obsolete.
Performs the regression using the input and output data, returning the sum of squared errors of the fit.
Public methodToString
Returns a System.String representing the regression.
(Overrides ObjectToString.)
Public methodToString(IFormatProvider)
Returns a System.String representing the regression.
Public methodToString(String)
Returns a System.String representing the regression.
Public methodToString(String, IFormatProvider)
Returns a System.String representing the regression.
Public methodTransform(TInput)
Applies the transformation to a set of input vectors, producing an associated set of output vectors.
(Inherited from TransformBaseTInput, TOutput.)
Public methodTransform(Double)
Applies the transformation to an input, producing an associated output.
(Overrides TransformBaseTInput, TOutputTransform(TInput).)
Public methodTransform(TInput, TOutput)
Applies the transformation to an input, producing an associated output.
(Inherited from TransformBaseTInput, TOutput.)
Top
Extension Methods
  NameDescription
Public Extension MethodHasMethod
Checks whether an object implements a method with the given name.
(Defined by ExtensionMethods.)
Public Extension MethodToTOverloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by ExtensionMethods.)
Public Extension MethodToTOverloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by Matrix.)
Top
Remarks
In linear regression, the model specification is that the dependent variable, y is a linear combination of the parameters (but need not be linear in the independent variables). As the linear regression has a closed form solution, the regression coefficients can be efficiently computed using the Regress method of this class.
See Also