bedpe1:
chr1 100 200 chr1 400 500
chr1 1000 1200 chr1 1500 1600
bedpe2
chr2 40 150 chr1 350 500
chr1 70 150 chr1 450 550
The first entry in bedpe1 overlaps with the second entry in bedpe2.
---------|---------|-----------------------|----------|-----
-----|---------|-------------------------|---------------|---
merged to
-----|-------------|---------------------|---------------|---
This is just an example for intra-chromosomal merging.
Ideally, one can specify, how merging should be performed. minimal overlappings:
--------|------|---------------------------|-----------|-----