This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Samtools Rmdup, file output empty

Hello,

I am trying to output a file that removed PCR duplicates by using rmdup command. My file is single-ends.

I put this into my terminal: samtools rdup [-s] input_path_file_directory > output_path_file_and_file_name.bam

It makes the file, the only thing is that the file is empty. Any ideas why?

Thanks

pcr next-gen samtools ngs

Are you using this command?

samtools rmdup -s input.bam output.bam

You don't need '>' symbol to get the output bam.

Exactly :-)

Thank you! I overlooked that, and got the results I needed!

1 answer

samtools rmdup -s input.bam out.bam

input.bam must be sorted (samtools sort).

Log in to answer this question.