(howto) Perform local realignment around indelsPosted in Tutorials on 2013-06-17 21:07:46 | Last updated on 2015-07-27 16:45:16

Objective

Perform local realignment around indels to correct mapping-related artifacts.

• TBD

Steps

1. Create a target list of intervals to be realigned
2. Perform realignment of the target intervals

1. Create a target list of intervals to be realigned

Action

Run the following GATK command:

java -jar GenomeAnalysisTK.jar \
-T RealignerTargetCreator \
-R reference.fa \
-L 20 \
-known gold_indels.vcf \
-o realignment_targets.list


Expected Result

This creates a file called realignment_targets.list containing the list of intervals that the program identified as needing realignment within our target, chromosome 20.

The list of known indel sites (gold_indels.vcf) are used as targets for realignment. Only use it if there is such a list for your organism.

2. Perform realignment of the target intervals

Action

Run the following GATK command:

java -jar GenomeAnalysisTK.jar \
-T IndelRealigner \
-R reference.fa \

This creates a file called realigned_reads.bam containing all the original reads, but with better local alignments in the regions that were realigned.
Note that here, we didn’t include the -L 20 argument. It's not necessary since the program will only run on the target intervals we are providing.