Entering edit mode
9.1 years ago
Ming Tommy Tang
★
4.5k
What is the fastest way to sort a very big bam? (300GB)
I have read this Efficient And Fastest Way To Sort Large (>100Gb) Bam Files? but it is a bit old post. sambamba seems to outperform samtools.
What's your experiences with sorting big bam files now?
Thanks,
Ming
+1 for samtools rocksort.
I got curious and tried sambamba and I'm quite impressed! A quick test with an unsorted bam of ~78M reads (4.3G):
samtools Version: 1.1 (using htslib 1.1):
Now sambamba:
sambamba also uses considerably less memory. Finally, it appears that leaving the output filename as default you get as a bonus the index file for the sorted output (!!)