How to extract brushed data from a surf plot in the form of a matrix?

2 次查看(过去 30 天)
Hi all,
I have 2736x1920 matrix from which I create a surf plot, I then brush some values from the plot and extract them in the following manner:
Handle = surf(Z);
h = brush;
set(h,'Enable','on');
brushed = logical(get(Handle, 'BrushData'));
'brushed' is a 2736x1920 logical array. I want to extract all the brushed values from 'Z' into a new matrix. but when I do:
brushed_val = Z(brushed);
I get a column vector.
Any ideas how can I get a submatrix of 'Z' that contains the 'trues' that are given in 'brushed'?
thanks.

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Surface and Mesh Plots 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by