How to remove plot based on markers

  • Follow


I have a plot on which I have some data plotted with different markers. How do I delete the data from the plot based on markers?

a = 1:10;
b = sin(a);
c = cos(a);
hold on;
plot(a,b, '+', 'markersize',6);
plot(a,c, 'v', 'markersize',8);

Now I want to remove all the data plotted with marker 'v' on the plot, how to I do it? 

Thanks a lot!
0
Reply Yuping 3/18/2010 4:44:04 PM

Yuping Liang wrote:
> I have a plot on which I have some data plotted with different markers. 
> How do I delete the data from the plot based on markers?
> 
> a = 1:10;
> b = sin(a);
> c = cos(a);
> hold on;
> plot(a,b, '+', 'markersize',6);
> plot(a,c, 'v', 'markersize',8);
> 
> Now I want to remove all the data plotted with marker 'v' on the plot, 
> how to I do it?

delete(findobj(gca,'Type','line','Marker','v'));
0
Reply Walter 3/18/2010 4:52:01 PM


1 Replies
229 Views

(page loaded in 0.076 seconds)

Similiar Articles:













7/18/2012 5:12:37 AM


Reply: