You are here: Start » AVL.NET » AVL.FitLineToPoints(AvlNet.Point2D[], AvlNet.Line2D, float)
AVL.FitLineToPoints(AvlNet.Point2D[], AvlNet.Line2D, float)
Approximates points with a line using the Least Squares method.
| Namespace: | AvlNet |
|---|---|
| Assembly: | AVL.NET.dll |
Syntax
public static void FitLineToPoints( AvlNet.Point2D[] inPoints, out AvlNet.Line2D outLine, out float outError )
Parameters
- inPoints
- Type: AvlNet.Point2D
- outLine
- Type: AvlNet.Line2D
- outError
- Type: System.Single
Examples
![]() |
The resulting outLine drawn with the input points.
Errors
| Error type | Description |
|---|---|
| DomainError | Empty point array in FitLineToPoints. |

