bed2idx: Match bed-like entries to Hi-C bin indices

View source: R/utils.R

bed2idxR Documentation

Match bed-like entries to Hi-C bin indices

Description

Match bed-like entries to Hi-C bin indices

Usage

bed2idx(IDX, bed, mode = c("centre", "start", "end"))

Arguments

IDX

The IDX-slot of a contacts object

bed

A 3-column data.frame

mode

A character of length 1 indicating what position of the bed argument to match with the indices. Possible values: "center", "start" or "end".

Details

Out of bounds values are matched to nearest bin.

Value

An integer vector of length nrow(bed) and parallel to bed with indices to the Hi-C matrix.


robinweide/GENOVA documentation built on March 14, 2024, 11:16 p.m.