findInterval() with right-closed intervals

后端 未结 3 610
既然无缘
既然无缘 2020-12-13 15:07

The great findInterval() function in R uses left-closed sub-intervals in its vec argument, as shown in its docs:

if i

3条回答
  •  春和景丽
    2020-12-13 15:38

    If your limits are intervals you simply can grow the right interval a bit: interval+c(0,0.1) would do: findinterval(value, interval+c(0,0.1))

提交回复
热议问题