eqPercent#
- swordfish.function.eqPercent()#
Check element-wise equality of two inputs X and Y are equal within the specified toleranceLevel.
- Parameters:
X (Constant) – A scalar, vector, pair, or matriX. Supported data types include BOOL, CHAR, SHORT, INT, LONG, FLOAT, DOUBLE, DECIMAL. Note: X and Y must be of the same form, and elements in X and Y can be of different data types.
Y (Constant) – X and Y are two numbers to compare. They must be scalars, vectors, pairs, or matrices of the same shape. Supported data types include BOOL, CHAR, SHORT, INT, LONG, FLOAT, DOUBLE, DECIMAL. Note: X and Y must be of the same form, and elements in X and Y can be of different data types.
toleranceLevel (Constant, optional) – A number in (0, 100), representing the tolerable percentage error. The default value is 0.0001. This means the absolute difference between the two elements must not exceed the toleranceLevel percentage of the absolute value of Y.
- Returns:
A Boolean scalar.
Note
If the type of the input X or Y is not supported, the function returns the result of eqObj(X, Y).
Null values are not equal to other values.
Null values of different types are considered equal.
- Return type: