On Di, 2015-04-07 at 00:49 +0100, Nicholas Devenish wrote:
> With the indexing example from the documentation:
>
> y = np.arange(35).reshape(5,7)
>
> Why does selecting an item from explicitly every row work as I’d expect:
> >>> y[np.array([0,1,2,3,4]),np.array([0,0,0,0,0])]
> array([ 0, 7, 14,
On Mon, Apr 6, 2015 at 4:49 PM, Nicholas Devenish wrote:
> With the indexing example from the documentation:
>
> y = np.arange(35).reshape(5,7)
>
> Why does selecting an item from explicitly every row work as I’d expect:
y[np.array([0,1,2,3,4]),np.array([0,0,0,0,0])]
> array([ 0, 7, 14, 21,
xpert, though.
Nikolay.
> From: misno...@gmail.com
> Date: Tue, 7 Apr 2015 00:49:34 +0100
> To: numpy-discussion@scipy.org
> Subject: [Numpy-discussion] Multidimensional Indexing
>
> With the indexing example from the documentation:
>
> y = np.arange(35).reshape(5,7)
>
&
With the indexing example from the documentation:
y = np.arange(35).reshape(5,7)
Why does selecting an item from explicitly every row work as I’d expect:
>>> y[np.array([0,1,2,3,4]),np.array([0,0,0,0,0])]
array([ 0, 7, 14, 21, 28])
But doing so from a full slice (which, I would naively expect t