Documentation of 'jnumeric.BinaryUfunc' Java class
BinaryUfunc
jnumeric

Class BinaryUfunc

  • All Implemented Interfaces:
    java.io.Serializable


    public class BinaryUfunc
    extends KeywordFunction
    Universal functions that take two PyMultiarrays as input.
    See Also:
    Serialized Form
    • Field Detail

      • add

        public static final jnumeric.BinaryFunction add
        Adds two arrays.
      • subtract

        public static final jnumeric.BinaryFunction subtract
        Subtracts two arrays.
      • multiply

        public static final jnumeric.BinaryFunction multiply
        Multiplies two arrays.
      • divide

        public static final jnumeric.BinaryFunction divide
        Divides two arrays.
      • remainder

        public static final jnumeric.BinaryFunction remainder
        Finds the remainder after dividing two arrays.
      • power

        public static final jnumeric.BinaryFunction power
        Takes an array to the power of another.
      • maximum

        public static final jnumeric.BinaryFunction maximum
        Finds the maximum values between two arrays.
      • minimum

        public static final jnumeric.BinaryFunction minimum
        Finds the minimum values between two arrays.
      • equal

        public static final jnumeric.BinaryFunction equal
        Finds where two arrays are equal.
      • notEqual

        public static final jnumeric.BinaryFunction notEqual
        Finds where two arrays are not equal.
      • less

        public static final jnumeric.BinaryFunction less
        Finds where an array is less than another array.
      • lessEqual

        public static final jnumeric.BinaryFunction lessEqual
        Finds where an array is less than or equal to another array.
      • greater

        public static final jnumeric.BinaryFunction greater
        Finds where an array is greater than another array.
      • greaterEqual

        public static final jnumeric.BinaryFunction greaterEqual
        Finds where an array is greater than or equal to another array.
      • logicalAnd

        public static final jnumeric.BinaryFunction logicalAnd
        Takes the logical and of two binary arrays.
      • logicalOr

        public static final jnumeric.BinaryFunction logicalOr
        Takes the logical or of two binary arrays.
      • logicalXor

        public static final jnumeric.BinaryFunction logicalXor
        Takes the logical exclusive-or of two binary arrays.
      • bitwiseAnd

        public static final jnumeric.BinaryFunction bitwiseAnd
        Does a bitwise and between two arrays.
      • bitwiseOr

        public static final jnumeric.BinaryFunction bitwiseOr
        Does a bitwise or between two arrays.
      • bitwiseXor

        public static final jnumeric.BinaryFunction bitwiseXor
        Does a bitwise exclusive-or between two arrays.
      • argMax

        public static final jnumeric.BinaryFunction argMax
        Finds the index of the largest elements between two arrays.
      • argMin

        public static final jnumeric.BinaryFunction argMin
        Finds the index of the smallest elements between two arrays.
    • Constructor Detail

      • BinaryUfunc

        public BinaryUfunc(jnumeric.BinaryFunction function)
        Wraps a BinaryFunction into a universal function.
        Parameters:
        function - The function to wrap
    • Method Detail

      • __findattr_ex__

        public PyObject __findattr_ex__(java.lang.String name)
        Description copied from class: PyObject
        Attribute lookup hook. If the attribute is not found, null may be returned or a Py.AttributeError can be thrown, whatever is more correct, efficient and/or convenient for the implementing class. Client code should use PyObject.__getattr__(String) or PyObject.__findattr__(String). Both methods have a clear policy for failed lookups.
        Overrides:
        __findattr_ex__ in class KeywordFunction
        Returns:
        The looked up value. May return null if the attribute is not found
      • outer

        public PyObject outer(PyObject poa,
                              PyObject pob)
        Takes the outer product of a and b. The new results shape will be the same as a.shape + b.shape (where plus means concatenate, not add!)
        Parameters:
        poa - PyMultiArray a
        pob - PyMultiArray b
        Returns:
        Outer produce of poa and pob.
      • reduceat

        public PyObject reduceat(PyObject po,
                                 int[] indices,
                                 int axis)
        This is a weird function, and most people should just ignore it. It will reduce a to each of the given indices so that as new size along the given axis will be the same as the length of indices. If axis is not supplied it defaults to zero.
        Parameters:
        po - Input PyMultiArray
        indices - The indices to reduce to
        axis - Axis along which to reduce (default: 0)
        Returns:
        The reduced array, with size == indices.length
      • reduceat

        public PyObject reduceat(PyObject po,
                                 int[] indices)
        Overloaded function for if no axis is passed. Defaults to 0.
        Parameters:
        po - Input PyMultiArray
        indices - The indices to reduce to
        Returns:
        result of reduceat(po, indices, 0)
        See Also:
        reduceat(PyObject, int[], int)
      • reduce

        public PyObject reduce(PyObject po,
                               int axis)
        Works just like reduce(ufunc, a, [ufunc's identity element]) except you get to choose the axis to perform the reduction along. Note that if the length of a long axis is 0, then the appropriate identity element for the ufunc will be returned.
        Parameters:
        po - Input PyMultiArray
        axis - Axis along which to reduce (default: 0)
        Returns:
        Result of reducing the ufunc
      • reduce

        public PyObject reduce(PyObject po)
        Overloaded reduce, defaults axis to 0.
        Parameters:
        po - Input PyMultiArray
        Returns:
        Result of calling reduce(po, 0)
        See Also:
        reduce(PyObject, int)
      • accumulate

        public PyObject accumulate(PyObject po,
                                   int axis)
        This is the same as reduce, except that all the intermediate results are kept along the way.
        Parameters:
        po - Input PyMultiArray
        axis - Axis over which to reduce (default: 0)
        Returns:
        The intermediate results of reducing po
      • accumulate

        public PyObject accumulate(PyObject po)
        Overloaded accumulate, defaults axis to 0.
        Parameters:
        po - Input PyMultiArray
        Returns:
        Result of calling accumulate(po, 0)
        See Also:
        accumulate(PyObject, int)

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.