Description Usage Arguments Value See Also Examples
The function almost.unique
extracts elements of a vector x
that are unique up to a tolerance factor.
1 2 3 4 5 | almost.unique(x, ...)
## Default S3 method:
almost.unique(x, tolerance = sqrt(.Machine$double.eps),
...)
|
x |
numeric. The vector of numeric values at stake. |
... |
Additional arguments to be passed to the function
|
tolerance |
numeric. Relative differences smaller than tolerance are considered as equal.
The default value is close to |
A vector of the same type as x
.
1 2 3 4 5 6 | almost.unique(c(1, 1.01), tol = 0.1)
almost.unique(c(1, 1.01), tol = 0.01)
almost.unique(c(1, 2, 3), tol = 10)
almost.unique(c(1, 2, 3), tol = 5)
almost.unique(c(1, 2, 3), tol = 1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.