almostZero {oceanwaves} | R Documentation |
Test whether vector elements are effectively zero
Description
Test whether elements in vector x are effectively zero, within the square root of machine tolerance for a floating point number.
Usage
almostZero(x, y = 0, tolerance = sqrt(.Machine$double.eps))
Arguments
x |
Numeric vector of values to compared against 0 |
y |
Value to be compared against. Default is 0. |
tolerance |
The maximum difference between x and y necessary to call a value non-zero |
Details
Returns TRUE for all vector elements that are within rounding error of zero.
Value
TRUE or FALSE for each element of the vector x.
[Package oceanwaves version 0.2.0 Index]