How do you find the overlapping coordinates and extract the respective seg.mean values for the overlapping region?
data1
Rl pValue chr start end CNA
2 2.594433 6 129740000 129780000 gain
2 3.941399 6 130080000 130380000 gain
1 1.992114 10 80900000 81100000 gain
1 7.175750 16 44780000 44920000 gain
data2
ID chrom loc.start loc.end num.mark seg.mean
8410 6 129750000 129760000 8430 0.0039
8410 10 80907000 81000000 5 -1.7738
8410 16 44790000 44910000 12 0.0110
dataoutput
Rl pValue chr start end CNA seg.mean
2 2.594433 6 129750000 129760000 gain 0.0039
1 1.992114 10 80907000 81000000 gain -1.7738
1 7.175750 16 44790000 44910000 gain 0.0110
See Question&Answers more detail:os