Dear numpy users,

I think since long I am confused by if a function works as expected or not
for masked array.
like np.reshape works for masked array, but not np.sum (I mean, I expect
np.sum to drop the masked elements when do summing, of course we have
np.ma.sum).
So I always use fuctions preceding by np.ma to make sure there is nothing
going woring if I expect there will be masked array participating in the
calculation in the data process chain.

When I handle masked array, Before I use a function, normally I check if
there is an equivalent np.ma function and if there is, I use
np.mafunction; Then I check how the documentation says about np.func
and
np.ma.func and see there is anything mentioned explicitly on the handling
of masked array.  Howevery, In most cases I will try with simple arrays to
test both np.ma.func and np.func before I use some function. but this is
sometimes time consuming. Does anyone have similar situation?

thanks!

Chao
-- 
***********************************************************************************
Chao YUE
Laboratoire des Sciences du Climat et de l'Environnement (LSCE-IPSL)
UMR 1572 CEA-CNRS-UVSQ
Batiment 712 - Pe 119
91191 GIF Sur YVETTE Cedex
Tel: (33) 01 69 08 29 02; Fax:01.69.08.77.16
************************************************************************************
_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to