dask.array.result_type

Contents

dask.array.result_type#

dask.array.result_type(*arrays_and_dtypes)[source]#

This docstring was copied from numpy.result_type.

Some inconsistencies with the Dask version may exist.

Returns the type that results from applying the NumPy type promotion rules to the arguments.

Parameters:
arrays_and_dtypeslist of arrays and dtypes

The operands of some operation whose result type is needed.

Returns:
outdtype

The result type.

See also

dtype, promote_types, min_scalar_type, can_cast

Examples

>>> import numpy as np
>>> np.result_type(3, np.arange(7, dtype='i1'))
dtype('int8')
>>> np.result_type('i4', 'c8')
dtype('complex128')
>>> np.result_type(3.0, -2)
dtype('float64')