Code covered by the BSD License  

Highlights from
snare

4.0

4.0 | 1 rating Rate this file 6 Downloads (last 30 days) File Size: 3.71 KB File ID: #25573
image thumbnail

snare

by James Roberts

 

14 Oct 2009

perform basic manipulation on 2D subsets of a data set

| Watch this File

File Information
Description

Given a vector of x- and y-coordinates of a data set, allows the user to select a subset of the data with the mouse and change the coordinates of that subset much as he/she moves icons around a desktop. There are three modes of selecting the data - 'lasso-ing' the data much like in MS Paint, a rectangular selection much like the desktop icon selection function, and by adding points to a path surrounding the data one point at a time. Snare.m also returns the indices of the data set that are selected last.

Once the user selects a subset of points, he/she may press the left mouse button anywhere within the path and drag the points to a new location. The relative location of the points selected remains constant.

Snare.m automatically pulls up a new window displaying the data and all operations to select and manipulate the data are performed with the mouse. The function is exited by closing the figure window. The indices returned are the indices of the last set of data to be selected.

MATLAB release MATLAB 7.5 (R2007b)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (1)
06 Jun 2010 grega

Hi,

Nice application. Thank you!

Would be good if all indices could be recorded, not just from last selection. Hopefully in next version.

Please login to add a comment or rating.
Tag Activity for this File
Tag Applied By Date/Time
data James Roberts 14 Oct 2009 12:02:11
data processing James Roberts 14 Oct 2009 12:02:11
data manipulation James Roberts 14 Oct 2009 12:02:11
data selection James Roberts 14 Oct 2009 12:02:11
scatterplot James Roberts 14 Oct 2009 12:02:11
mouse James Roberts 14 Oct 2009 12:02:11
graphics James Roberts 14 Oct 2009 12:02:11
interactive plot Pavan 20 Jan 2010 03:54:42

Contact us at files@mathworks.com