BAM to FASTQ
# single end
bedtools bamtofastq [OPTIONS] -i <BAM> -fq <FASTQ>
# pair end
bedtools bamtofastq -i aln.qsort.bam \
-fq aln.end1.fq \
-fq2 aln.end2.fqLast updated
# single end
bedtools bamtofastq [OPTIONS] -i <BAM> -fq <FASTQ>
# pair end
bedtools bamtofastq -i aln.qsort.bam \
-fq aln.end1.fq \
-fq2 aln.end2.fqLast updated