[SciPy-dev] slicing using Index and Mask arrays

Travis Oliphant oliphant at ee.byu.edu
Sat Jun 5 00:10:04 CDT 2004

I have just added a feature to scipy in CVS

This feature lets

a[a > 3] = 10
a[indexarray] = 3

and so forth  to function.

a[maskarray]  and a[indexarray]
always return a 1-d array (multidimensional returns not yet supported)

a[maskarray] = obj   and a[indexarray]= obj
will keep the shape of a

To enable the new feature you must type (we will do this by default on 
scipy import at some point)


You can get back old numeric behavior using


Please report any bugs you find...

-Travis O.

More information about the Scipy-dev mailing list