Given a four-element vector of start and end coordinates of two events, cross_time() compares the distances among the upper and lower boundaries of pairs of event vectors. This includes "like" boundary comparison (e.g., start #2 - start#1) and contrary boundary comparison (e.g. start #2 - end #1).

cross_time(
  s0,
  s1,
  e0,
  e1,
  control = list(-Inf, Inf),
  chatty = FALSE,
  unit = NULL,
  cache = NULL,
  ...
)

Arguments

s0

A numeric/date-coded vector containing the temporal lower boundary of the starting event duration

s1

A numeric/date-coded vector containing the temporal upper boundary of the starting event duration

e0

A numeric/date-coded vector containing the temporal lower boundary of the ending event duration

e1

A numeric/date-coded vector containing the temporal upper boundary of the ending event duration

control

A length-2 sorted list with values indicating the range of allowable values for internal variable beta (the difference between ends of 'to' events and beginnings of 'from' events)

chatty

(logical | FALSE) Verbosity flag

unit

One of the lubridate d<duration>() functions

cache

(Optional) A cache_disk, cache_disk object, or TRUE which defaults to cache_disk

...

(Not used)

Value

A data.table object having the following fields:

mGap:

Metric describing the difference between the following temporal boundaries: TO.start, FROM.end

mSt:

Metric describing the difference between the following temporal boundaries: TO.start, FROM.start

mEd:

Metrics describing the difference between the following temporal boundaries: TO.end, FROM.end

from_len:

The duration of time of each "from" event: units are one the scale of the smallest increment of time represented (e.g., calendar dates in days will have lengths expressed in days)

to_len:

The duration of time of each "to" event: units are one the scale of the smallest increment of time represented (e.g., calendar dates in days will have lengths expressed in days)

epsilon:

A complex number (e.g., 1337 + 0.90210i) describing the relational changes from one event to another with interpretation based on whether or not the real and imaginary parts are > 0, < 0, or == 0:

ReImDesc
> 00Disjoint
0> 0Concurrency
> 0> 0Full Concurrency
00Continuity
< 1to event shorter than from event
= 1to event same length as from event
> 1to event longer than from event
epsilon_desc:

A plain-language description of epsilon