dellytools / delly

DELLY2: Structural variant discovery by integrated paired-end and split-read analysis
BSD 3-Clause "New" or "Revised" License
413 stars 136 forks source link

Question about delly's selectInversions() function in short-read call #372

Closed q-wind closed 3 months ago

q-wind commented 4 months ago

Hello, I'm reading the Delly's source code, and I am confused about the way the selectInversions() function identifies inversion in shortpe.h line426. In my understanding, the selectInversions() function in junction.h iterates over each JunctionVector in readBp. In the previous processing, each JunctionVector corresponds to the junctions of a certain read, and the forward field in these Junction structures is set to have the same alignment direction as the rec in the _insertJunction(). So, in selectInversions() junction.h line195 how can we got two Junction with different forward? I haven't understood this part yet. I hope to get your help. Thank you so much! Qingwen

q-wind commented 3 months ago

I realized that when parsing CIGAR value, the secondary and supplementary alignment of read were not excluded, but rather processed. Therefore, the corresponding JunctionVector can contain junction with different alignment directions. Is this right?

tobiasrausch commented 3 months ago

Yes, that's right.

q-wind commented 3 months ago

Thanks for your help!