MATLAB: How can i find a specific member of an array

arrayconditionfindplot

Hello everybody,
I have an array full of calculated values. I need to find a fraction of it where it meets a specific condition and plot it.
How can i do that?

Best Answer

idx=find(diff(A)>0);
idx=[idx idx(end)+1];
B=A(idx)