For each of given values, indx finds the index of the value in a
vector sorted in ascending order that the given value is barely greater than
or equal to.
Usage
indx(x, v)
Arguments
x
vector of numeric values, the indices of which are to be found.
v
vector of numeric values sorted in ascending order.
Value
Returns a vector of integers, that are indices of x-values in vector
v.
Details
For each x[i], the function returns integer j such that $$v_j \le x_i <
v_{j+1}$$ where \(v_0 = - \infty \mathrm{ and }
v_{n+1} = \infty\).