Line Simplification

버전 (6.03 KB) 작성자: Wolfgang Schwanghart
Recursive Douglas-Peucker Polyline Simplification (Iterative Endpoint Fit)

다운로드 수: 7.8K

업데이트 날짜: 2010/7/13

라이선스 보기

편집자 메모: This file was selected as MATLAB Central Pick of the Week

dpsimplify uses the recursive Douglas-Peucker line simplification algorithm to reduce the number of vertices in a polyline according to a specified tolerance. The algorithm is also know as Iterative Endpoint Fit algorithm. dpsimplify can handle polylines and polygones in 2d and higher dimensions.

The submission now contains another m-file (dpsimplify_octave.m) that has been slightly modified to run with GNU Octave.


[ps,ix] = dpsimplify(p,tol)

where p is a nxm matrix that contains n vertices in m dimensions.

For additional information on the algorithm follow this link

인용 양식

Wolfgang Schwanghart (2023). Line Simplification (, MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2007b
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
Help CenterMATLAB Answers에서 Octave에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
버전 게시됨 릴리스 정보

added m-file that runs with GNU Octave

Added some information in the description.

Removed a bug in calculating the second output argument. Improved handling of lines with only one segment.

only minor changes: added some comments and changed the link to more information since it was dead.

First, the algorithm can now handle nans in the vertex array. It assumes that nans in the array serve as separator of single polylines and treats each polyline/polygon separately.