[Numpy-discussion] Fancy indexing question:

Christopher Barker Chris.Barker at noaa.gov
Thu Feb 26 16:29:32 EST 2009


Ravi wrote:
> Use ix_:
> 
> In [5]: a[ ix_(i,j) ]
> Out[5]:
> array([[ 5,  7],
>        [13, 15],
>        [17, 19]])

Very nice!


thanks,
-Chris



-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov



More information about the NumPy-Discussion mailing list