Format
BAM
Binary, compressed SAM. Must be coordinate-sorted and indexed before most tools will accept it.
Extensions: .bam, .bai · Coordinates: 1-based-closed · Specification
From BAM
- How to Convert BAM to CRAM (and What Changes Between Builds)
CRAM cuts your disk usage roughly in half and quietly makes the file unreadable without the exact reference FASTA it was built against.
- How to Convert BAM to FASTQ (Commands, Checks, and Pitfalls)
The two-step pattern that keeps paired reads paired, plus the default flag that quietly drops reads you didn't know you were missing.
To BAM
- How to Convert SAM to BAM (Commands, Checks, and Pitfalls)
samtools view converts the bytes; sort and index are what make the BAM actually usable downstream.