3D Surf linkdata brush delete selected data
Afficher commentaires plus anciens
Hi there,
I am attempting to visually select data from a surface plot using the "Brush" mode in order to delete the selected data.
The problem I encounter is that everytime I select data using brush as well as linkdata to update the source variables I only get to select the data columnwise; meaning I cannot select individual areas but only whole slices of the data, which is not what I want. I searched on the web and consulted forums but could not solve the problem. Find enclosed the code; I sure hope sb. has an idea or a workaround for this.
Cheers Oliver
%%GridFit
load('ASC')
% Generates mesh
Nodesx = min(ASC.x):5:max(ASC.x)
Nodesy = min(ASC.y):5:max(ASC.y)
% GridFit of data onto mesh
[zg,xg,yg] = gridfit(ASC.x,ASC.y,ASC.z,Nodesx,Nodesy, ...
'smooth',0.01, ...
'interp','triangle', ...
'solver','normal', ...
'regularizer','laplacian', ...
'extend','warning', ...
'tilesize',inf);
%%Surf plot
box off
h=surf(xg,yg,zg)
% Specifies the data sources for editing
set(h,'YDataSource','yg')
set(h,'XDataSource','xg')
set(h,'ZDataSource','zg')
% links the data sources
linkdata on
% enables the brushing mode
brush on
% Plot style options
shading interp
camlight right; lighting phong
% Controlls display of heights //
axis tight
zlim([-150 150]) % Defines scale for representing heights
colormap(jet(1000))
set(gca,'zticklabel',[],'ztick',[]);
xlabel('x [cm]');ylabel('y [cm]')
cb = colorbar('vert');zlab = get(cb,'ylabel');
set(zlab,'String','Eelvation [cm]','fontsize',11);
x1=get(gca,'position');x=get(cb,'Position');x(3)=0.01;
set(cb,'Position',x); set(gca,'position',x1)
set(gca,'fontsize',11)
% View options;
% view(2) % For brushing use Birdview
view([-35 60]); % View for final output
2 commentaires
Oliver
le 29 Nov 2012
Freddie Santiago
le 14 Mar 2013
How you solve the problem? I am experiencing the same problem, I want to select specific points to brush but it selects the columns.
Thanks
Réponses (1)
JP Belliard
le 22 Mar 2014
0 votes
Hey, I am facing the same problem. I also want to select a particular regrion of my surf plot but it selects all the columns. How did you solve it? Thanks
Catégories
En savoir plus sur Lighting, Transparency, and Shading dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!