dot-zero_range: Check whether all elements of a numeric vector are identical...

Description Usage Arguments Value Note

Description

Check whether all elements of a numeric vector are identical (within machine precision)

Usage

1
.zero_range(x, tol = .Machine$double.eps^0.5)

Arguments

x

a numeric vector.

Value

TRUE if all elements of the vector are identical (within machine precision). FALSE in all other cases, including if the vector contains any NAs.

Note

This function is based on Hadley and John's answer to http://stackoverflow.com/q/4752275. No check is made that x is a numeric vector.


GenomicTuples documentation built on Nov. 8, 2020, 6:43 p.m.