intersect_intervals#
- alphagenome.data.genome.intersect_intervals(lhs, rhs, *, result_strand='.')[source]#
Generates the intersection of two interval sets.
Point ranges (width == 0) are considered to intersect any range which contains them.
In these examples, the intersection is a point range
(2, 2):1 2 3 4 ..|..|..|..|.. <> (start=2, end=2) -------> (..., end=2) 1 2 3 4 ..|..|..|..|.. <> (start=2, end=2) <------- (start=2, end=...)
For consistency, this means that the following results in a point intersection:
1 2 3 4 ..|..|..|..|.. -------> (start=..., end=2) <------- (start=2, end=...)
- Parameters:
- Yields:
- The intersection of intervals. Overlapping intervals within either
lhs or
rhsare implicitly unioned.
- The intersection of intervals. Overlapping intervals within either
- Return type: