
Merges segments that are in the same chromosome arm AND have the same ratio_median.
GatherSegmentsByRatioMedian.Rd
Most of the work is done by GatherSegmentsByRatioMedianHelper. Essentially, we iterate through the rows of
bam_ratios_frame
, and keep track of adjacent rows that have the same ratio_median and are in the same chromosome arm.
Whenever any of these 2 conditions is false, we merge the segments up until that point. More information is in the helper function.
Finally, adds a 'Size' column to bam_ratios_frame
.