Date: Jul 22, 2013 11:56 AM
Author: Antonio Valentine
Subject: find position in a vector

Hello there,

I have a vector of



>> x = [200;500;400;480;900;560;820;0]

I want to have a vector Y that x > 200. So I wrote

>> y = x(x > x(1))

So I get "500 400 480 900 560 820"

It returns me a value. But I need to know a position e.g.

I need the return of y = [2 3 4 5 6] not y = [ 500 400 480 900 560 820];

How should I do in this case? It is quite simple but I really have no idea.

Thank you

AV.