My project loads a data file of anywhere between 100 and 100,000 data points, and then plots them on a graph.

Currently I'm trying to figure out what's the most efficient way to do this? Plotting 100,000 data points on a graph would take a long long time (I think).

Currently, I create two const double arrays and curve->setSamples(x, y, n), but I don't know how well this works for large arrays. Is there some function or method by which I can plot a fraction of the data points (say one in ten?), and then still be able to see all the data points when I zoom in?

Thanks for any help