Least-Squares fitting the points (x,y) to a line y : x -> a+b*x,
returning its best fitting parameters as (a, b) tuple,
where a is the intercept and b the slope.
Namespace: Altaxo.CalcAssembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3572.0 (4.8.3572.0)
Syntaxpublic static (double A, double B) Line(
double[] x,
double[] y
)
Parameters
- x Double
- The x values of the sample points.
- y Double
- The y values of the sample points.
Return Value
ValueTupleDouble,
DoubleThe intercept and slope of the fitted line.
See Also