I'm puzzled by a seeming discrepancy between what is displayed in IGV, and what is actually contained in my BAM file. Here is the IGV display:
The highlighted column is at chr1:1012318. The second read in the pileup aligns with edit distance zero starting at this position. However, here is what this read actually looks like in the BAM file:
HSQ1009_86:8:2105:11117:123998 147 chr1 1012318 0 39S61= = 1011329 -1050 GGGACTCCGTGGGGGGAGGCGGAGGCTATGGGGACTCCGTGGGGGGAGGCTGAGGCTACGGGGACTCCGTGGGGGGAGGCTGAGGCTACGGGGACTCCGT #######################################@@;8DDEC@@;7C>@;;:-'CGG@5IIIHHGJGGJJJIJIJJJJJJJJHHHHHFDFFFCCB
As expected, the read has a start alignment position of 1012318. However, if you look at the actual sequence, there are nine bases (GGGACTCCG
) which precede what is actually displayed in IGV! I'm confused because I thought the alignment position always marked where the start of the read aligns. Can someone explain what is going on? samtools tview
shows the same thing.
FYI: This should be added as a comment to Pierre's answer, and not an answer itself.