pile: Get IDs of intervals covering each sub-interval
Description
Get the intervals overlapping each section as a list.
Usage
pile(x, interval_names = rownames(x), output = "list")
Value
See notes on output
parameter.
Arguments
- x
Integer matrix of two columns, the first column giving the (inclusive) start points of intervals and the second column giving the corresponding (exclusive) end points.
- interval_names
Character vector of names for each interval, not necessarily unique. If they are not unique, one might wish to lapply
unique
to the list of members for each sub-interval returned by this function. Defaults to the rownames
of x
.
- output
Character value either "list"
or "vector"
determining whether a named list of interval index/name vectors or flat vector of members (corresponding to the output of depth
) is returned.