title: Reducing/Simplifying time-series data
body: <p>I have time-series data I'm looking to simplify (Reduce the number of points while having the graph maintain the same shape). For example if I had this data set:</p>
  
  <pre><code>Time: 1, Value: 5
  Time: 6, Value: 5
  Time: 11, Value: 5.1
  Time: 12, Value: 5
  Time: 20, Value: 5.2
  Time: 22, Value: 6
  Time: 23, Value: 10
  </code></pre>
  
  <p>The simplified version with a tolerance of .5 would be something like:</p>
  
  <pre><code>Time: 1, Value: 5
  Time: 20, Value: 5.2
  Time: 22, Value: 6
  Time: 23, Value: 10
  </code></pre>
  
  <p>I'm aware of the Douglas–Peucker algorithm for GIS data but I'm not sure how to apply it to time-series data as the axises have different units. It would be awesome if I could do this all in the database.</p>