This is a test version of Biostars. For the public version, visit https://www.biostars.org.
BBmap: how to map ONLY paired-end reads to the reference

Hi,

I am using BBmap to map paired-end DNA reads to a reference and want to map pairs only without mapping individual mates similar to --no-mixed option in bowtie2.

Could someone help me with this?

Thanks!

bbmap

so you want BBmap to only report a mapping if both reads of a pair maps?

if so, have a look at the pairedonly=f option (put it to t for your case)

Yes, i will try that. Thanks for the help.

1 answer

Try the following option with bbmap.sh. I don't know if this is only referring to reads that are not a proper pair.

pairedonly=t            (po) Treat unpaired reads as unmapped.  Thus they will 
                        be sent to 'outu' but not 'outm'.

Otherwise you can do something like:

bbmap.sh <options> out=stdout.bam | reformat.sh in=stdin.bam out=final.bam pairedonly=t            

pairedonly=f            Toss reads that are not mapped as proper pairs.

I want to toss the reads that map but don't have a pair. Thank you for your help.

Log in to answer this question.