This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How to check if BAM is indel-realigned?

I have a few BAM files from collaborators and I do not know if these were indel-realigned. People who was working on these files are no longer working in the lab, so I have no sources of information about details of these alignments. Is there a way to check if these files were indel-realigned?

gatk indel-realignment bam alignment

1 answer

search a program group in the bam header for gatk IndelRealigner

e.g:https://github.com/samtools/samtools/blob/9df632114a537f57928e4b2c17fbb1928679f877/test/dat/mpileup.1.sam

@PG ID:bam_realignment_around_known_indels.1    PN:GenomeAnalysisTK PP:gatk_target_interval_creator.1   VN:1.2-29-g0acaf2d  CL:java $jvm_args -jar GenomeAnalysisTK.jar -T IndelRealigner -R $reference_fasta -I $bam_file -o $realigned_bam_file -targetIntervals $intervals_file -known $known_indels_file(s) -LOD 0.4 -model KNOWNS_ONLY -compress 0 --disable_bam_indexing
@PG ID:bam_realignment_around_known_indels.2    PN:GenomeAnalysisTK PP:gatk_target_interval_creator.2   VN:1.2-29-g0acaf2d  CL:java $jvm_args -jar GenomeAnalysisTK.jar -T IndelRealigner -R $reference_fasta -I $bam_file -o $realigned_bam_file -targetIntervals $intervals_file -known $known_indels_file(s) -LOD 0.4 -model KNOWNS_ONLY -compress 0 --disable_bam_indexing
@PG ID:bam_realignment_around_known_indels.3    PN:GenomeAnalysisTK PP:gatk_target_interval_creator.3   VN:1.2-29-g0acaf2d  CL:java $jvm_args -jar GenomeAnalysisTK.jar -T IndelRealigner -R $reference_fasta -I $bam_file -o $realigned_bam_file -targetIntervals $intervals_file -known $known_indels_file(s) -LOD 0.4 -model KNOWNS_ONLY -compress 0 --disable_bam_indexing

yay it worked! thanks

Log in to answer this question.