LinearRegression
StockSharp.Algo.Indicators
The full class of linear regression, calculates LinearReg, LinearRegSlope, RSquared and StandardError at the same time.
Inherits: BaseComplexIndicator<ILinearRegressionValue>
Constructors
LinearRegression
public LinearRegression()
linearRegression = LinearRegression()
Initializes a new instance of the LinearRegression.
LinearRegression
public LinearRegression(LinearReg linearReg, LinearRegRSquared rSquared, LinearRegSlope regSlope, StandardError standardError)
linearRegression = LinearRegression(linearReg, rSquared, regSlope, standardError)
Initializes a new instance of the LinearRegression.
- linearReg
- Linear regression.
- rSquared
- Regression R-squared.
- regSlope
- Coefficient with independent variable, slope of a straight line.
- standardError
- Standard error.
Properties
Length
public int Length { get; set; }
value = linearRegression.Length
linearRegression.Length = value
Period length.
LinearRegSlope
public LinearRegSlope LinearRegSlope { get; }
value = linearRegression.LinearRegSlope
Coefficient with independent variable, slope of a straight line.
RSquared
public LinearRegRSquared RSquared { get; }
value = linearRegression.RSquared
Regression R-squared.
StandardError
public StandardError StandardError { get; }
value = linearRegression.StandardError
Standard error.
Methods
CreateValue
protected override ILinearRegressionValue CreateValue(DateTime time)
result = linearRegression.CreateValue(time)
Create .
- time
- Time
Load
public override void Load(SettingsStorage storage)
linearRegression.Load(storage)
Load settings.
- storage
- Settings storage.
Save
public override void Save(SettingsStorage storage)
linearRegression.Save(storage)
Save settings.
- storage
- Settings storage.
ToString
public override string ToString()
result = linearRegression.ToString()
Преобразовать к строковому представлению.
Returns: Строковое представление.