API Reference

Public

GenomicFeatures.coverageFunction
coverage(intervals)

Compute the coverage of a collection of intervals and return an IntervalCollection that contains run-length encoded coverage data.

For example, given intervals like:

[------]     [------------]
   [---------------]

This function would return a new set of disjoint intervals with annotated coverage like:

[1][-2-][-1-][--2--][--1--]
source
GenomicFeatures.eachoverlapFunction
eachoverlap(intervals_a, intervals_b, [seqname_isless=Base.isless])

Create an iterator of overlapping intervals between intervals_a and intervals_b.

This function assumes elements of intervals_a and intervals_b are sorted by its sequence name and left position. If the element type is not a subtype of GenomicFeatures.Interval, elements are converted to Interval objects.

The third optional argument is a function that defines the order of sequence names. The default function is Base.isless, which is the lexicographical order.

source

Private

Base.findfirstMethod

Find a the first interval with matching start and end points.

Returns that interval, or 'nothing' if no interval was found.

source
GenomicFeatures.isorderedMethod

Check if two intervals are well ordered.

Intervals are considered well ordered if a.seqname <= b.seqnamend and a.first <= b.first.

source