[Numpy-discussion] Status of numeric3 / scipylite / scipy_core
Paul Barrett
barrett at stsci.edu
Fri Mar 18 07:10:29 EST 2005
Perry Greenfield wrote:
> Before I delve too deeply into what you are suggesting (or asking),
> has the idea to have a slice be equivalent to an index array been
> changed. For example, I recall seeing (I forget where), the suggestion
> that
>
> X[:,ind] is the same as X[arange(X.shape[0]), ind]
>
> The following seems to be at odds with this. The confusion of mixing
> slices with index arrays led me to just not deal with them in
> numarray. I thought index arrays were getting complicated enough. I
> suppose it may be useful, but I would be good to give some motivating,
> realistic examples of why they are useful. For example, I can think of
> lots of motivating examples for:
>
> using more than one index array (e.g., X[ind1, ind2])
> allowing index arrays to have arbitrary shape
> allowing partial indexing with index arrays
Can you give a few then? Say one or two for each of the three scenarios.
--
Paul Barrett, PhD Space Telescope Science Institute
Phone: 410-338-4475 ESS/Science Software Branch
FAX: 410-338-4767 Baltimore, MD 21218
More information about the NumPy-Discussion
mailing list