Code covered by the BSD License  

Highlights from
Interactive Data Navigation Pane Widget

4.72727

4.7 | 12 ratings Rate this file 36 Downloads (last 30 days) File Size: 12.1 KB File ID: #23423
image thumbnail

Interactive Data Navigation Pane Widget

by

 

25 Mar 2009 (Updated )

Widget to interactively & graphically select a section of a large dataset you want to work on

Editor's Notes:

This file was selected as MATLAB Central Pick of the Week

| Watch this File

File Information
Description

This widget will give you access to one of the most common task you have to perform when you manipulate large data sets:
Selecting within this large data set what portion of data you want to work on.

This easy to use widget will enable you to:

- Interactively define the section of your data set you want to work on. To do so you just have to drag and drop cursors that define the limits of your section

- Automatically execute callbacks when you start dragging one of the cursors, while you are dragging the cursor and when you release the cursor

See the demo_uiHistory.m file for a preview of how to use this widget.

MATLAB release MATLAB 7.8 (R2009a)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (15)
24 Feb 2014 Mark Jackson

Great bit of code. I updated it to allow linear or log scale selection on both the axes but the "fill" colour doesn't work for log scales (a log scale rendering issue)

13 Jan 2014 Ronan CIMADURE  
16 Dec 2013 francesco

very useful tool

10 Nov 2013 Giorgos Papakonstantinou  
20 Feb 2013 Eric Cheng  
19 Feb 2013 arnold

Great submission.

I second the ideas of Yair, especially, that you should make the selected area "dragable"! That would really round it off! Thx!

28 Oct 2011 Sourin  
20 Jun 2011 Calvin Hsieh

Great submission.

However, I keep getting a "Input argument "cursorPosition" is undefined error. Can you comment?

03 Jun 2011 farzad

sounds useful but I couldnt use it.
please consider the fact that not everyone here is advanced in MATLAB. How should we pass the inputs to this widget inside our code?
what is 'parent'? how should the 'data' be defined?

25 Mar 2010 Robert Barrie

If you are doing time series data manipulation, you might also like Thomas' other example 'Graphical Points Selection'. Great work. Thanks heaps!

25 Mar 2010 Robert Barrie  
25 Mar 2010 Robert Barrie  
13 Apr 2009 Yan

For those who do not have 7.6 or later (uiHistory). same feature can be readily developed by using :
http://www.mathworks.com/matlabcentral/fileexchange/13857

28 Mar 2009 Yair Altman

Very nice execution!

I was planning on doing something similar based on Google Finance's example, but with your submission there's really no need. An altogether excellent submission and a fine example of Matlab OOP.

A few suggestions:
1) uiHistory works on R2008a (Matlab 7.6) onward. You might consider some coding changes for it to work on R2007b and earlier: 'private' instead of private (and so on for other modifiers); not inheriting hgsetget etc.
2) You might consider modifying the cursor over the handle bars to right-left arrows (see my ScrollPlot submission for example)
3) You might consider setting the central patch (between the handle bars) draggable, so that the user can interactively pan the zoomed contents (again, see ScrollPlot for example)
4) You might consider enabling the two edit-boxes, so that users can enter specific dates.
5) You might consider adding a shading between the zoom patch below and the displayed graph above, just like in your screenshot. For some reason I don't see this on my R2008a/b.
6) You might consider adding to the main graph axes annual grid-lines (like in the zoom axes below) and tick labels (so that we know what event happened when)
7) Finally, I would suggest displaying the figure toolbar, or at least enable data-cursor mode (whose callback should be modified to display a human-readable date).

26 Mar 2009 Jonathan Lister

First class coding! Nice work. I love the new classdef.

Updates
06 Feb 2013

Updated cursor object

Contact us