/dist_pt_line

Matlab toolbox containing algorithms for computing distances from point to line and RANSAC for doing robust line-fit.

Primary LanguageMATLABMIT LicenseMIT

dist_pt_line

Computes distance from Point to Line with MATLAB functions

General Demo

  • demo_pt_line.m - runs demo_2d.m and demo_nd.m

2D Functions (works just in 2D)

  • demo_2d.m - 2D demo
  • line_2d.m - computes line equation ax + by + c = 0 from two points
  • dist_2d.m - computes distance from point to line

N-D Functions (works in any dimension)

  • demo_nd.m - N-D demo
  • line_nd.m - computes line equation from two points
  • dist_nd.m - computes distance from point to line

RANSAC Line Fit (fits the best line when outliers exist)