So ran into an interesting outcome from samtools filtering. I'm attempting to select reads in which one member of the pair is mapped, but the other is not. After searching for the best filtering for that, most people seemed to indicate -f 11
was the correct choice for this. However, that includes "properly paired" which seems like something I don't want. Additionally when I used -f 11
I get nothing coming out. I decided to try -f 9
which removes the proper pairing component and that seemed to work for my needs.
Can anyone explain why the posts I've seen in the past suggest -f 11
and whether or not this has an internal contradiction which yields no reads?
So that was my thought as well, I think the code you listed essentially mirrors doing
-f 9
and-f 5
togetherIt is very easy to make nonsensical flags (unfortunately a flaw of the SAM spec itself) ... not to mention the awkward constructs: a primary alignment is an alignment that is not secondary, not supplementary and not unmapped ...