How to reduce the number of points in (x,y) data

Posted by Gowtham on Stack Overflow See other posts from Stack Overflow or by Gowtham
Published on 2010-04-12T16:39:24Z Indexed on 2010/04/12 16:43 UTC
Read the original article Hit count: 212

Filed under:
|

I have a set of data points:

(x1, y1) (x2, y2) (x3, y3) ... (xn, yn)

The number of sample points can be thousands. I want to represent the same curve as accurately as possible with minimal (lets suppose 30) set of points. I want to capture as many inflection points as possible. However, I have a hard limit on the number of allowed points to represent the data.

What is the best algorithm to achieve the same? Is there any free software library that can help?

PS: I have tried to implement relative slope difference based point elimination, but this does not always result in the best possible data representation.

Thanks for your time.

-Gowtham

© Stack Overflow or respective owner

Related posts about data

Related posts about reduction