DSPLOT - downsampled plot

version (4.58 KB) by Jiro Doke
This function creates a downsampled plot to improve the speed of exploration (zoom, pan)


Updated Thu, 01 Sep 2016 15:06:50 +0000

View License

Editor's Note: This was a File Exchange Pick of the Week

This version of "plot" will allow you to visualize data that has very large number of elements. Plotting large data set makes your graphics sluggish, but most times you don't need all of the information displayed in the plot. Your screen only has so many pixels, and your eyes won't be able to detect any information not captured on the screen.
This function will downsample the data and plot only a subset of the data, thus improving the memory requirement. When the plot is zoomed in, more information gets displayed. Some work is done to make sure that outliers are captured.

dsplot(x, y)
dsplot(x, y, numpoints)

x =linspace(0, 2*pi, 1000000);

Cite As

Jiro Doke (2022). DSPLOT - downsampled plot (https://www.mathworks.com/matlabcentral/fileexchange/15850-dsplot-downsampled-plot), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2007a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Inspired: jplot, Stability Analyzer 53230A

Community Treasure Hunt

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

Start Hunting!