Click here to Skip to main content
13,297,266 members (72,221 online)
Click here to Skip to main content
Add your own
alternative version

Tagged as


2 bookmarked
Posted 14 Feb 2013

Matlab Delta Cursors

, 14 Feb 2013
Rate this:
Please Sign up or sign in to vote.
Delta Cursors For Use In Matlab Figures


Within Matlab Figures, there are no delta data cursors. You have to export the data tips and then do the math yourself. This is a simple solution.


Since Matlab won't create the delta data cursors (data tips), here is a quick fix. This doesn't require much programming. Just adding the file to your path.

Using the code

Just add the file 'figureC.m' to your path. Replace calls to Matlab's built in 'figure' function with calls to 'figureC'. The custom figure will override the datacursormode's 'UpdateFcn' with its own custom function. It will automatically create the delta data cursors when there is more than one data cursor in a figure.

Points of Interest 

This function takes advantage of Matlab's 'UserData' which is embedded in every figure. Within UserData the reference data cursor object is stored. When data cursors update they use the embedded reference cursor object to find the delta and add it to the printout text.


  • Initial release: 2/13/2013.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Seth B Wood
United States United States
No Biography provided

You may also be interested in...

Comments and Discussions

Questionhelp Pin
plg_swpu28-Jun-13 17:09
memberplg_swpu28-Jun-13 17:09 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.171207.1 | Last Updated 14 Feb 2013
Article Copyright 2013 by Seth B Wood
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid