I am wondering about to use a BAM file output as a input to make a alignment to others FASTA reference genome. I have been reading how to get a FASTA format from my BAM file but I am not sure if the reads depth could affect my alignment. If that is possible, How could I do that?
Command line to remap a position sorted bam: "samtools collate -uOn128 old-pos-srt.bam tmpxyz | samtools fastq - | bwa mem -pt16 ref.fa - | samtools sort --threads=4 -m4G -o new-pos-srt.bam"