combineVariants error for merging two vcf files
0
0
Entering edit mode
6.8 years ago
GK1610 ▴ 120

Hi I have 2 vcf files vcf1 from WGS data vcf2 from genotype data I am trying to merge these two files using combinevariants

GenomeAnalysisTK_jar=gatk/3.5-0/GenomeAnalysisTK.jar
java -jar $GenomeAnalysisTK_jar -T CombineVariants -R $REF --variant $vcf1 --variant $vcf2 -o $outputfile

I am getting this error

MESSAGE: The provided variant file(s) have inconsistent references for the same position(s) at 21:11098723, T* vs. A*

ERROR ------------------------------------------------------------------------------------------

when i grep these position in vcf1

21 11098723 . T C

21 11098724 . G A

vcf2

21 11098723 exm1562347 A G

how can i fix this error?

snp gatk combinevariants • 2.4k views
ADD COMMENT
0
Entering edit mode

you cannot have two differents alleles at the same position at 11098723. It looks more like a bug in your upstream worklow (working with two different builds ?).

how can i fix this error?

grep out the bad lines, or replace the reference allele ?

ADD REPLY
1
Entering edit mode

You could try updating all REF alleles t match a particular reference genome by using bcftools norm with the following command-line parameters:

--check-ref <e|w|x>
-f, --fasta-ref <file>

...although it rarely appears to function.

ADD REPLY
1
Entering edit mode

Thanks, yeah this works :)

ADD REPLY

Login before adding your answer.

Traffic: 1786 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6