Draggable data tips

版本 1.1.0.1 (4.8 KB) 作者: Yair Altman
Enable dragging Matlab plot data-tips
1.2K 次下载
更新时间 2019/3/14

查看许可证

Matlab plots can display data-tips but these cannot be interactively moved except to the 4 corners of the data point.

This utility enables the user to interactively drag any newly-created data-tip, anywhere in the Matlab figure. A dashed line connects the dragged data-tip with the original data point.

The new draggable functionality only affects new data-tips, so it can be turned on/off to enable standard and new data-tips to co-exist in the same plot (see screenshot).

Syntax: draggableDataTips(newState)

Examples:
draggableDataTips('on') or draggableDataTips(true) turns the new functionality ON for new data-tips.
draggableDataTips('off') or draggableDataTips(false) turns the new functionality OFF for new data tips.

Warning:
Relies on undocumented functionality.
This utility fails in HG2 (R2014b+) - please don't bug me about it, unless you found a solution...
On HG2 (R2014b+), use Allen's submission: https://www.mathworks.com/matlabcentral/fileexchange/69799-dragdatatip

Technical description:
http://UndocumentedMatlab.com/blog/draggable-plot-data-tips

引用格式

Yair Altman (2024). Draggable data tips (https://www.mathworks.com/matlabcentral/fileexchange/44065-draggable-data-tips), MATLAB Central File Exchange. 检索时间: .

MATLAB 版本兼容性
创建方式 R2010b
兼容 R2014a 及更早的版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Graphics Object Programming 的更多信息
致谢

启发作品: DragDataTip

Community Treasure Hunt

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

Start Hunting!
版本 已发布 发行说明
1.1.0.1

No code change; only clarified in the Description section that this utility fails on R2014b or newer. Users of recent Matlab releases should use Allen's submission instead (see comment on 3 Jan 2019).

1.1.0.0

Fixed the bug reported by Aditya on Nov 3, 2013

1.0.0.0