[Numpy-discussion] Silly array question

Webb Sprague webb.sprague at gmail.com
Fri Apr 7 14:05:04 EDT 2006


Ok, so now I get it

M[(tuple for rows), (tuple for columns)]

Whew

On 4/7/06, Webb Sprague <webb.sprague at gmail.com> wrote:
> I appreciate everyone's help, but is there a NON obfuscated way to do
> this without looping?  I think Chris's is my favorite, but I didn't
> know I was starting a contest :)
>
> >  >>> M[I[:,0], I[:,1]]
> > array([ 1,  6, 11,  6])
>
> W
>




More information about the NumPy-Discussion mailing list