This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Samtools flagstat unpaired reads

Trying to quickly remove reads samtools flagstat deems as unpaired from BAM file? Thanks.

samtools bam bowtie2

Have you searched Biostars (use external google search) for past threads? There has to be something available already.

1 answer

remove unpaired files = reads that are not part of a paired-end experiment ?

samtools view -f 1 -b -o out.bam in.bam

Yes just for BAM files already processed for removal of duplicates (Picard) and ChrM and ChrUN reads.

Log in to answer this question.