find_interval | R Documentation |
When vec
is in ascending order we use base::findInterval()
, but
when vec
is in descending order we implement an adaptation of the
locate()
function from Numerical Recipes for C http://apps.nrbook.com/c/index.html
find_interval(x, vec, rightmost.closed = FALSE, all.inside = FALSE)
x |
numeric values we wish to located within |
vec |
numeric vector of sorted values (ascending or descending order)
within which we wish to find the placement of |
rightmost.closed |
see findInterval |
all.inside |
see findInterval |
see findInterval
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.