joinIntervalsAND: Join two sets of intervals using an AND logic

Description Usage Arguments Value Examples

View source: R/JoinIntervals.R

Description

To be included in the output interval, the time period needs to be included in both set of time intervals. Adjacent s1-e1 or s2-e2 will be joined together by default

Usage

1
joinIntervalsAND(s1, e1, s2, e2)

Arguments

s1

Numeric vector containing the start times of the first set of intervals

e1

Numeric vector containing the end times of the first set of intervals

s2

Numeric vector containing the start times of the second set of intervals

e2

Numeric vector containing the end times of the second set of intervals

Value

matrix containing the start and end of the resulting intervals. First col is the start times. Second col is end times.

Examples

1
2
3
4
5
s1<-c(0,20000)
e1<-c(500,25000)
s2<-c(250,24000)
e2<-c(600,30000)
joinIntervalsAND(s1,e1,s2,e2)

kevin-allen/relectro documentation built on May 20, 2019, 9:06 a.m.