No subject


Thu Nov 16 16:52:29 CST 2006


  The result of a unary operation will be masked whenever the original
  operand was masked.... The following functions have their standard
  meaning

   absolute, ...., sin, ...

I would have expected this to work

    import numarray as nx
    import numarray.ma as ma
    t = nx.arange(0.0, 2.0, 0.01)
    tm = ma.masked_outside(t, .2, 1.2)
    s = nx.sin(tm)

but instead I get 

/usr/lib/python2.4/site-packages/numarray/ma/MA.py in __array__(self, t)
    673         if self._mask is not None:
    674             if Numeric.any(self._mask):
--> 675                 raise MAError, \
    676                 """Cannot automatically convert masked array to Numeric because data
    677                    is masked in one or more locations.

MAError: Cannot automatically convert masked array to Numeric because data
                   is masked in one or more locations.


I see the same with Numeric and MA

Am I misreading this?  Does "have their standard meaning" mean that MA
is not supported?


In [8]: numarray.__version__
Out[8]: '1.3.2'

In [9]: Numeric.__version__
Out[9]: '24.0b2'



JDH




More information about the Numpy-discussion mailing list