ScrollPlot adds a scroll sub-window to any supplied plot handles (or current [gca] axes if no handle was supplied). This enables easy plot or image exploration.
The user may specify initial view window parameters or use the defaults.
Dragging the side-bars or central patch modifies the parent axes limits interactively. Conversely, modifying the parent axes limits (with zoom, pan or programatically) modifies the corresponding scroll patch(es).
Both X & Y scrolling are possible.
Scrollplot works ok with log and reverse axes. ScrollPlot works on Matlab 6 (R12) and up.
scrollHandles = scrollplot(plotHandles, propName,propValue,...)
>> scrollplot; % add scroll sub-window to the current axes (gca)
>> scrollplot(plot(xdata,ydata), 'WindowSize',50); % plot with initial zoom
>> scrollplot('Min',20, 'windowsize',70); % add x-scroll to current axes
>> scrollplot([h1,h2], 'axis','xy'); % scroll both X&Y of 2 plot axes
>> scrollplot('axis','xy', 'minx',20, 'miny',10); % separate scroll minima
See extensive help within.
This code relies in [small] part on undocumented and unsupported Matlab functionality. It works on Matlab 6+, but use at your own risk!
Bugs and suggestions:
Please send to Yair Altman (altmany at gmail dot com)
See the bottom of this webpage
This ScrollPlot was inspired by Steve Lord's scrollplot demo submission, but is an entirely new implementation with lots of new functionality.