Question: filtering pair-end bam file
0
gravatar for npetr
13 months ago by
npetr • 0
npetr • 0 wrote:

Hello, I am trying to filter a pairend bam file to get only forward reads in Galaxy. A bam filter from bamtools does not seem do exactly what I mean, in fact it seems that it filters both read 1 and read 2 but I would like to only have read 1 filtered in order to obtain only fragments mapped to forward strand. Could you please suggest a correct way to do this?

bam • 605 views
ADD COMMENT • link • modified 13 months ago • written 13 months ago by npetr • 0

Hey, thank you very much for your reply Jen, so do you mean this filtering result in Pair End bam file containing only pairs where read 1 is mapped to forward strand? best Natalia

ADD REPLY • link written 13 months ago by npetr • 0

This filters to leave reads that are mapped to the forward strand. These are not necessarily the first read in a properly paired mapped pair.

ADD REPLY • link modified 13 months ago • written 13 months ago by Jennifer Hillman Jackson ♦ 25k
0
gravatar for Jennifer Hillman Jackson
13 months ago by
United States
Jennifer Hillman Jackson ♦ 25k wrote:

Hello,

Try the tool NGS: BamTools > Filter BAM datasets on a variety of attributes. There is an option to filter on "isReverseStrand" that can be used as a negative, to then leave only forward stranded reads if "isMapped" is also set.

You can filter in more advanced ways: properly paired reads, first or second read in the pair, and strand - all in one query. This tutorial covers how: https://galaxyproject.org/tutorials/ngs/#flag-field

Thanks, Jen, Galaxy team

ADD COMMENT • link modified 13 months ago • written 13 months ago by Jennifer Hillman Jackson ♦ 25k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 169 users visited in the last hour