Learn R Programming

sigminer (version 2.3.1)

get_intersect_size: Get Overlap Size between Interval x and y

Description

Get Overlap Size between Interval x and y

Usage

get_intersect_size(x.start, x.end, y.start, y.end)

Value

a numeric vector.

Arguments

x.start

start position of interval x.

x.end

start position of interval x.

y.start

start position of interval x.

y.end

start position of interval x.

Examples

Run this code
o1 <- get_intersect_size(1, 5, 3, 20)
o1
o2 <- get_intersect_size(3, 20, 1, 10)
o2
o3 <- get_intersect_size(c(1, 2, 1), c(10, 4, 6), c(4, 2, 5), c(10, 3, 22))
o3

Run the code above in your browser using DataLab