Yeah seems like there's no way to fix the BAM file as of now so I have to realign my reads. Cheers.
Hi everyone,
I generated a BAM file after aligning my NGS reads against the reference genome using BWA. My reference genome contains ALT contigs but I did not supply the .alt index file during alignment. I know I can just do the alignment again with the .alt index file but before I proceed to that, I am curious if there are any tools that can correct the alignment information in the BAM file as if I supplied the .alt index file during alignment.
Many thanks.
1 answer
I am not aware of any solution for this. I would realign. Be sure to use the ALT-aware version of bwa via bwa-kit when including ALT into the reference.
It is also safer to start from scratch if this is possible. Custom filtering is hard to reproduce at times.
Log in to answer this question.