- ArrayType
ArrayType = mu.ndarray
- Bool
Bool = _dt_(bool)
- Character
Character = 'S1'
- Complex
Complex = _dt_(complex)
- Complex0
Complex0 = _dt_(complex)
- Complex16
Complex16 = 'F'
- Complex32
Complex32 = _dt_(nt.complex64)
- Complex64
Complex64 = _dt_(nt.complex128)
- Complex8
Complex8 = 'F'
- Float
Float = _dt_(float)
- Float0
Float0 = _dt_(float)
- Float16
Float16 = 'f'
- Float32
Float32 = _dt_(nt.float32)
- Float64
Float64 = _dt_(nt.float64)
- Float8
Float8 = 'f'
- Int
Int = _dt_(int)
- Int0
Int0 = _dt_(int)
- Int16
Int16 = _dt_(nt.int16)
- Int32
Int32 = _dt_(nt.int32)
- Int8
Int8 = _dt_(nt.int8)
- LittleEndian
LittleEndian = sys.byteorder== 'little'
- NewAxis
Use this to add a new axis to an array
compatibility only
NewAxis = None
- PyObject
PyObject = _dt_(nt.object_)
- UFuncType
deprecated
UFuncType = type(um.sin)
- UInt16
UInt16 = UnsignedInt16
- UInt32
UInt32 = UnsignedInt32
- UInt8
UInt8 = UnsignedInt8
- UfuncType
UfuncType = type(um.sin)
- UnsignedInt
UnsignedInt = _dt_(nt.uint)
- UnsignedInt16
UnsignedInt16 = _dt_(nt.uint16)
- UnsignedInt32
UnsignedInt32 = _dt_(nt.uint32)
- UnsignedInt8
UnsignedInt8 = _dt_(nt.uint8)
- UnsignedInteger
UnsignedInteger = 'L'
- around
around = round_
- arrayrange
backward compatibility
arrayrange = mu.arange
- arraytype
arraytype = mu.ndarray
- cross_correlate
cross_correlate = correlate
- innerproduct
innerproduct = mu.inner
- matrixmultiply
deprecated names
matrixmultiply = mu.dot
- outerproduct
outerproduct = outer
- typecodes
typecodes = { Const('Character') : Const('S1'), Const('Integer') : Const('bhilqp'), Const('UnsignedInteger') : Const('BHILQP'), Const('Float') : Const('fdg'), Const('Complex') : Const('FDG'), Const('AllInteger') : Const('bBhHiIlLqQpP'), Const('AllFloat') : Const('fdgFDG'), Const('All') : Const('?bhilqpBHILQPfdgFDGSUVO') }
- alen(a)
Return the length of a Python object interpreted as an array
- all(x, axis = None)
Return true if all elements of x are true: alltrue(ravel(x))
- alltrue(x, axis = 0)
Perform a logical_and over the given axis.
- amax(a, axis = 0)
Return the maximum of 'a' along dimension axis.
- amin(a, axis = 0)
Return the minimum of a along dimension axis.
- any(x, axis = None)
Return true if any elements of x are true: sometrue(ravel(x))
- argmax(a, axis = -Const(1))
argmax(a,axis=-1) returns the indices to the maximum value of the
1-D arrays along the given axis.
- argmin(a, axis = -Const(1))
argmin(a,axis=-1) returns the indices to the minimum value of the
1-D arrays along the given axis.
- argsort(a, axis = -Const(1))
argsort(a,axis=-1) return the indices into a of the sorted array
along the given axis, so that take(a,result,axis) is the sorted array.
- choose(a, choices)
- clip(m, m_min, m_max)
clip(m, m_min, m_max) = every entry in m that is less than m_min is
replaced by m_min, and every entry greater than m_max is replaced by
m_max.
- compress(condition, m, axis = -Const(1))
compress(condition, x, axis=-1) = those elements of x corresponding
to those elements of condition that are "true". condition must be the
same size as the given dimension of x.
- cumprod(a, axis = 0)
Return the cumulative product of the elments along the given axis
- cumproduct(x, axis = 0, dtype = None)
Sum the array over the given axis.
- cumsum(x, axis = 0, dtype = None)
Sum the array over the given axis.
- diagonal(a, offset = 0, axis1 = 0, axis2 = 1)
diagonal(a, offset=0, axis1=0, axis2=1) returns the given diagonals
defined by the last two dimensions of the array.
- mean(a, axis = 0, dtype = None)
- ndim(a)
- nonzero(a)
nonzero(a) returns the indices of the elements of a which are not zero,
a must be 1d
- prod(a, axis = 0)
Return the product of the elements along the given axis
- product(x, axis = 0, dtype = None)
Product of the array elements over the given axis.
- ptp(a, axis = 0)
Return maximum - minimum along the the given dimension
- put(a, ind, v)
put(a, ind, v) results in a[n] = v[n] for all n in ind
If v is shorter than mask it will be repeated as necessary.
In particular v can be a scalar or length 1 array.
The routine put is the equivalent of the following (although the loop
is in C for speed):
ind = array(indices, copy=False)
v = array(values, copy=False).astype(a, a.dtype)
for i in ind: a.flat[i] = v[i]
a must be a contiguous Numeric array.
- putmask(a, mask, v)
putmask(a, mask, v) results in a = v for all places mask is true.
If v is shorter than mask it will be repeated as necessary.
In particular v can be a scalar or length 1 array.
- rank(a)
Get the rank of sequence a (the number of dimensions, not a matrix rank)
The rank of a scalar is zero.
- ravel(m)
ravel(m) returns a 1d array corresponding to all the elements of it's
argument.
- repeat(a, repeats, axis = 0)
repeat elements of a repeats times along axis
repeats is a sequence of length a.shape[axis]
telling how many times to repeat each element.
If repeats is an integer, it is interpreted as
a tuple of length a.shape[axis] containing repeats.
The argument a can be anything array(a) will accept.
- reshape(a, newshape)
Change the shape of a to newshape. Return a new view object.
- resize(a, new_shape)
resize(a,new_shape) returns a new array with the specified shape.
The original array's total size can be any size. It
fills the new array with repeated copies of a.
Note that a.resize(new_shape) will fill array with 0's
beyond current definition of a.
- round_(a, decimals = 0)
Round 'a' to the given number of decimal places. Rounding
behaviour is equivalent to Python.
Return 'a' if the array is not floating point. Round both the real
and imaginary parts separately if the array is complex.
- sarray(a, dtype = None, copy = False)
- searchsorted(a, v)
searchsorted(a, v)
- shape(a)
shape(a) returns the shape of a (as a function call which
also works on nested sequences).
- size(a, axis = None)
Get the number of elements in sequence a, or along a certain axis.
- sometrue(x, axis = 0)
Perform a logical_or over the given axis.
- sort(a, axis = -Const(1))
sort(a,axis=-1) returns array with elements sorted along given axis.
- squeeze(a)
Returns a with any ones from the shape of a removed
- std(a, axis = 0, dtype = None)
- sum(x, axis = 0, dtype = None)
Sum the array over the given axis. The optional dtype argument
is the data type for intermediate calculations.
The default is to upcast (promote) smaller integer types to the
platform-dependent Int. For example, on 32-bit platforms:
x.dtype default sum() dtype
---------------------------------------------------
bool, Int8, Int16, Int32 Int32
Examples:
>>> sum([0.5, 1.5])
2.0
>>> sum([0.5, 1.5], dtype=Int32)
1
>>> sum([[0, 1], [0, 5]])
array([0, 6])
>>> sum([[0, 1], [0, 5]], axis=1)
array([1, 5])
- swapaxes(a, axis1, axis2)
swapaxes(a, axis1, axis2) returns array a with axis1 and axis2
interchanged.
- take(a, indices, axis = 0)
- trace(a, offset = 0, axis1 = 0, axis2 = 1, dtype = None)
trace(a,offset=0, axis1=0, axis2=1) returns the sum along diagonals
(defined by the last two dimenions) of the array.
- transpose(a, axes = None)
transpose(a, axes=None) returns array with dimensions permuted
according to axes. If axes is None (default) returns array with
dimensions reversed.
- var(a, axis = 0, dtype = None)