In Python: Lets say I have a matrix A=[4,3,2,1], now I want to find the location of numbers which are greater than or equal to 2 and less than 4? Please help me how to do this? Secondly, once I found the indices which are 2 and 3 in this case, and now I want to keep only those values in A which have the same indices and the first one, i.e. The new matrix should be A=[4,3,2].

Thanks in advance.

asked Jan 24 at 10:06

Imran's gravatar image

Imran
1111

Be the first one to answer this question!
toggle preview

powered by OSQA

User submitted content is under Creative Commons: Attribution - Share Alike; Other things copyright (C) 2010, MetaOptimize LLC.