MaskedArray.conjugate()

MaskedArray.conjugate() Return the complex conjugate, element-wise. Refer to numpy.conjugate for full documentation. See also numpy.conjugate equivalent function

MaskedArray.conj()

MaskedArray.conj() Complex-conjugate all elements. Refer to numpy.conjugate for full documentation. See also numpy.conjugate equivalent function

MaskedArray.compressed()

MaskedArray.compressed() [source] Return all the non-masked data as a 1-D array. Returns: data : ndarray A new ndarray holding the non-masked data is returned. Notes The result is not a MaskedArray! Examples >>> x = np.ma.array(np.arange(5), mask=[0]*2 + [1]*3) >>> x.compressed() array([0, 1]) >>> type(x.compressed()) <type 'numpy.ndarray'>

MaskedArray.compress()

MaskedArray.compress(condition, axis=None, out=None) [source] Return a where condition is True. If condition is a MaskedArray, missing values are considered as False. Parameters: condition : var Boolean 1-d array selecting which entries to return. If len(condition) is less than the size of a along the axis, then output is truncated to length of condition array. axis : {None, int}, optional Axis along which the operation must be performed. out : {None, ndarray}, optional Alternative ou

MaskedArray.clip()

MaskedArray.clip(min=None, max=None, out=None) [source] Return an array whose values are limited to [min, max]. One of max or min must be given. Refer to numpy.clip for full documentation. See also numpy.clip equivalent function

MaskedArray.choose()

MaskedArray.choose(choices, out=None, mode='raise') Use an index array to construct a new array from a set of choices. Refer to numpy.choose for full documentation. See also numpy.choose equivalent function

MaskedArray.byteswap()

MaskedArray.byteswap(inplace) Swap the bytes of the array elements Toggle between low-endian and big-endian data representation by returning a byteswapped array, optionally swapped in-place. Parameters: inplace : bool, optional If True, swap bytes in-place, default is False. Returns: out : ndarray The byteswapped array. If inplace is True, this is a view to self. Examples >>> A = np.array([1, 256, 8755], dtype=np.int16) >>> map(hex, A) ['0x1', '0x100', '0x2233'] &g

MaskedArray.base

MaskedArray.base Base object if memory is from some other object. Examples The base of an array that owns its memory is None: >>> x = np.array([1,2,3,4]) >>> x.base is None True Slicing creates a view, whose memory is shared with x: >>> y = x[2:] >>> y.base is x True

MaskedArray.astype()

MaskedArray.astype(newtype) [source] Returns a copy of the MaskedArray cast to given newtype. Returns: output : MaskedArray A copy of self cast to input newtype. The returned record shape matches self.shape. Examples >>> x = np.ma.array([[1,2,3.1],[4,5,6],[7,8,9]], mask=[0] + [1,0]*4) >>> print(x) [[1.0 -- 3.1] [-- 5.0 --] [7.0 -- 9.0]] >>> print(x.astype(int32)) [[1 -- 3] [-- 5 --] [7 -- 9]]

MaskedArray.argsort()

MaskedArray.argsort(axis=None, kind='quicksort', order=None, fill_value=None) [source] Return an ndarray of indices that sort the array along the specified axis. Masked values are filled beforehand to fill_value. Parameters: axis : int, optional Axis along which to sort. The default is -1 (last axis). If None, the flattened array is used. fill_value : var, optional Value used to fill the array before sorting. The default is the fill_value attribute of the input array. kind : {?quicksor