How to merge INFO fields in some files using GATK CombineVariants
0
0
Entering edit mode
8.2 years ago
Apprentice ▴ 170

Hi.

I would like to merge two vcf files (a.vcf, b.vcf) into one vcf file (c.vcf) using GATK CombineVariants.

a.vcf and b.vcf are shown as below;

$ cat a.vcf

CHROM POS ID REF ALT QUAL FILTER INFO FORMAT SampleA

chr1 11077009 . C . . PASS VAR_ID=a_1 GT:DP:RGQ 0/0:33:99 chr2 74592269 . G . . PASS VAR_ID=a_2 GT:DP:RGQ 0/0:22:60

$ cat b.vcf

CHROM POS ID REF ALT QUAL FILTER INFO FORMAT SampleB

chr1 11077009 . C . . PASS VAR_ID=b_1 GT:DP:RGQ 0/0:35:99 chr2 74592269 . G A . PASS VAR_ID=b_2 GT:AD:DP:GQ:PL 0/0:42,0:42:99:0,111,1205

Finaly, I want to get c.vcf using GATK CombineVariants as below; $ cat c.vcf

CHROM POS ID REF ALT QUAL FILTER INFO FORMAT SampleA SampleB

chr1 11077009 . C . . PASS VAR_ID=a_1,b_1 GT:DP:RGQ 0/0:33:99 0/0:35:99 chr2 74592269 . G A . PASS VAR_ID=a_2,b_2 GT:AD:DP:GQ:PL 0/0:22,0:60,0:: 0/0:42,0:42:99:0,111,1205

Please note that two vcf files have different VAR_ID values in INFO field, and I hope that both VAR_ID values are merged. How should I merge the files ?

SNP sequence • 2.0k views
ADD COMMENT

Login before adding your answer.

Traffic: 2331 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