MaskedArray.T

MaskedArray.T

numpy.promote_types()

numpy.promote_types(type1, type2) Returns the data type with the smallest size and smallest scalar kind to which both type1 and type2 may be safely cast. The returned data type is always in native byte order. This function is symmetric and associative. Parameters: type1 : dtype or dtype specifier First data type. type2 : dtype or dtype specifier Second data type. Returns: out : dtype The promoted data type. See also result_type, dtype, can_cast Notes New in version 1.6.0. Star

numpy.random.normal()

numpy.random.normal(loc=0.0, scale=1.0, size=None) Draw random samples from a normal (Gaussian) distribution. The probability density function of the normal distribution, first derived by De Moivre and 200 years later by both Gauss and Laplace independently [R250], is often called the bell curve because of its characteristic shape (see the example below). The normal distributions occurs often in nature. For example, it describes the commonly occurring distribution of samples influenced by a

numpy.sctype2char()

numpy.sctype2char(sctype) [source] Return the string representation of a scalar dtype. Parameters: sctype : scalar dtype or object If a scalar dtype, the corresponding string character is returned. If an object, sctype2char tries to infer its scalar type and then return the corresponding string character. Returns: typechar : str The string character corresponding to the scalar type. Raises: ValueError If sctype is an object for which the type can not be inferred. See also obj2s

Miscellaneous routines

Buffer objects getbuffer(obj [,offset[, size]]) Create a buffer object from the given object referencing a slice of length size starting at offset. newbuffer(size) Return a new uninitialized buffer object. Performance tuning alterdot() Change dot, vdot, and inner to use accelerated BLAS functions. restoredot() Restore dot, vdot, and innerproduct to the default non-BLAS implementations. setbufsize(size) Set the size of the buffer used in ufuncs. getbufsize() Return the size of the b

numpy.nditer

class numpy.nditer [source] Efficient multi-dimensional iterator object to iterate over arrays. To get started using this object, see the introductory guide to array iteration. Parameters: op : ndarray or sequence of array_like The array(s) to iterate over. flags : sequence of str, optional Flags to control the behavior of the iterator. ?buffered? enables buffering when required. ?c_index? causes a C-order index to be tracked. ?f_index? causes a Fortran-order index to be tracked. ?mult

numpy.matmul()

numpy.matmul(a, b, out=None) Matrix product of two arrays. The behavior depends on the arguments in the following way. If both arguments are 2-D they are multiplied like conventional matrices. If either argument is N-D, N > 2, it is treated as a stack of matrices residing in the last two indexes and broadcast accordingly. If the first argument is 1-D, it is promoted to a matrix by prepending a 1 to its dimensions. After matrix multiplication the prepended 1 is removed. If the second argu

RandomState.random_integers()

RandomState.random_integers(low, high=None, size=None) Random integers of type np.int between low and high, inclusive. Return random integers of type np.int from the ?discrete uniform? distribution in the closed interval [low, high]. If high is None (the default), then results are from [1, low]. The np.int type translates to the C long type used by Python 2 for ?short? integers and its precision is platform dependent. This function has been deprecated. Use randint instead. Deprecated since

Indexing routines

See also Indexing Generating index arrays c_ Translates slice objects to concatenation along the second axis. r_ Translates slice objects to concatenation along the first axis. s_ A nicer way to build up index tuples for arrays. nonzero(a) Return the indices of the elements that are non-zero. where(condition, [x, y]) Return elements, either from x or y, depending on condition. indices(dimensions[, dtype]) Return an array representing the indices of a grid. ix_(*args) Construct an open m

ndarray.__hex__()

ndarray.__hex__() <==> hex(x)