Usage
is.wholenumber(x, tol = .Machine$double.eps^0.5)
Arguments
- x
numeric(1). A numeric value
- tol
numeric(1). A precision tolerance.
Value
TRUE
if x
is within tol
of zero,
FALSE
otherwise.
Examples
is.wholenumber(5)
#> [1] TRUE
is.wholenumber(5.00000000000000001)
#> [1] TRUE
is.wholenumber(.5)
#> [1] FALSE