overlap2GR: Get a dataframe from findOverlaps from a GRangesList with 2...

Description Usage Arguments Value Examples

View source: R/myGRoverlapFunctions.R

Description

Get a dataframe from findOverlaps from a GRangesList with 2 items where colnames match the names of the items

Usage

1
overlap2GR(my2GRsToOverlap)

Arguments

my2GRsToOverlap

a GRangesList with 2 items to overlap

Value

a dataframe with 2 columns with colnames identicals to names of the input with the indices of the overlaps

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
gr1 <- GenomicRanges::GRanges(
seqnames = "chr1",
ranges = IRanges::IRanges(start = c(1, 11, 199),
                         end = c(10, 12, 200)),
score = c(20, 30, 100))
gr2 <- GenomicRanges::GRanges(
seqnames = "chr1",
ranges = IRanges::IRanges(start = c(5, 101),
                         end = c(15, 102)),
score = c(1, 2))
overlap2GR(list(first = gr1, second = gr2))

lldelisle/usefulLDfunctionsGR documentation built on Nov. 25, 2019, 11:24 a.m.