breaks
, determine in which
intervals the elements of a vector x
fall.R/RcppExports.R
find_interval.Rd
Given a vector of interval endpoints breaks
, determine in which
intervals the elements of a vector x
fall.
find_interval(x, breaks, rightmost_closed, all_inside)
vector for whose elements the corresponding intervals are identified
vector containing the elements
logical; if true, the results for x[j]=breaks[N] is N-1.
logical; if true, 0 is mapped to 1, and N is mapped to N-1
The rightmost interval is assumed to be closed. Compares to the behavior of
the findInterval
function in R
, when rightmost.closed =
TRUE
matrix containing the compartment counts at census times.