title: What are good strategies for graphing large datasets (1M +)?
body: <p>I'm just starting to approach this problem, I want to to allow users to arbitrarily select ranges and filters that allow them to graph large data sets (realistically it should never be more than 10 million data points) on a web page. I use elasticsearch as the method of storing and aggregating the data, along with redis for keeping track of summary data, and <a href="https://d3js.org/" rel="nofollow noreferrer">d3.js</a> is my graphing library.  </p>
  
  <p>My thoughts on the best solution is to have precalculated summaries in different groupings that can be used to graph from. So if the data points exist over several years, I can have groupings by month and day (which I would be doing anyway), but then by groupings of say half day, quarter day, hour, half hour, etc. And then before I query for graph data I do a quick calculation to see which of these groupings will give me some ideal number of data points (say 1000).</p>
  
  <p>Is this a reasonable way to approach the problem? Is there a better way?</p>