GUI manual data selection

1 次查看(过去 30 天)
Lukas
Lukas 2012-4-19
Is it possible to have the user select a data value from a plot using a cursor click on the plot?

采纳的回答

Jan
Jan 2012-4-19
Yes. The actual implementation depends on the type of the plot.
H = plot(1:10);
set(H, 'ButtonDownFcn', @myCallback);
function myCallback(ObjH, EvenData)
set(ObjH, 'Color', rand(1, 3));
AxesH = ancestor(ObjH, 'axes');
disp(get(AxesH, 'CurrentPoint'));

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Migrate GUIDE Apps 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by