<p>My problem was solved using <a href="https://gatk.broadinstitute.org/hc/en-us/articles/360037226512-LiftoverVcf-Picard-#--ALLOW_MISSING_FIELDS_IN_HEADER" rel="nofollow noreferrer">--ALLOW-MISSING-FIELDS-IN-HEADER</a>.</p>

CC BY-SA 4.0
2020-02-11T20:59:47.507Z
2020-02-11T20:59:47.507Z
CelineDion
<p>I am having a tough time calling LiftoverVcf in GATK. I have concatenated all of the Vcfs of interest and removed rows with problematic values but now when I run LiftoverVCF I get the following error:</p>

<pre><code>Intel; Inflater: Intel; Provider GCS is available; Picard version: Version:4.0.12.0
INFO 2020-02-10 14:36:03 LiftoverVcf Loading up the target reference genome.
INFO 2020-02-10 14:36:16 LiftoverVcf Lifting variants over and sorting (not yet writing the output file.)

[Mon Feb 10 14:59:31 EST 2020] picard.vcf.LiftoverVcf done. Elapsed time: 23.50 minutes.
Runtime.totalMemory()=7414480896
To get help, see http://broadinstitute.github.io/picard/index.html#GettingHelp
java.lang.IllegalStateException: Key . found in VariantContext field INFO at 1:121387974 but this key isn't defined in the VCFHeader. We require all VCFs to have complete VCF headers by default.
at htsjdk.variant.vcf.VCFEncoder.fieldIsMissingFromHeaderError(VCFEncoder.java:202)
at htsjdk.variant.vcf.VCFEncoder.write(VCFEncoder.java:141)
at htsjdk.variant.variantcontext.writer.VCFWriter.add(VCFWriter.java:248)
at picard.vcf.LiftoverVcf.rejectVariant(LiftoverVcf.java:456)
at picard.vcf.LiftoverVcf.doWork(LiftoverVcf.java:357)
at picard.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:295)
at org.broadinstitute.hellbender.cmdline.PicardCommandLineProgramExecutor.instanceMain(PicardCommandLineProgramExecutor.java:25)
at org.broadinstitute.hellbender.Main.runCommandLineProgram(Main.java:160)
at org.broadinstitute.hellbender.Main.mainEntry(Main.java:203)
at org.broadinstitute.hellbender.Main.main(Main.java:289)

</code></pre>

<p>Not sure why I am getting this error other than there may be a <code>.</code> in one of the info fields. Here is what the first several rows of my VCF looks like minus the header fields:</p>

<pre><code>#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT AltaiNea
1 10001 . T . 51.05 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=6.32;MQ0=242 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:21.05:0,21,265:1,2:0,1:1,0:116,129:2
1 10002 . A . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:6.01:0,6,69:171,184:0,9:0,0:0,2:0
1 10003 . A . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:6.02:0,6,72:222,201:1,0:0,0:0,8:0
1 10004 . C . 39.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.61;MQ0=247 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:9.02:0,9,97:0,1:268,211:0,0:0,1:0
1 10005 . C . 41.99 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.31;MQ0=246 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:12:0,12,119:0,0:341,287:0,0:0,0:0
1 10006 . C . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:6.02:0,6,72:0,1:408,347:0,0:2,0:0
1 10007 . T . 39.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.21;MQ0=246 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:9.02:0,9,97:0,0:0,0:0,0:506,451:0
1 10008 . A . 33.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.05;MQ0=247 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:3.01:0,3,40:547,507:0,0:0,0:0,0:0
1 10009 . A . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:6.02:0,6,70:600,534:0,1:0,0:0,1:0
1 10010 . C . 42.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.72;MQ0=244 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:12.02:0,12,125:0,0:649,547:0,1:1,0:0
1 10011 . C . 51.02 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=5.12;MQ0=242 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:21.03:0,21,209:0,2:732,612:0,1:0,0:0
1 10012 . C . 44.99 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.94;MQ0=243 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:14.99:0,15,141:0,3:804,657:0,0:6,1:0
1 10013 . T . 57.04 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.20;MQ0=238 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:27.04:0,27,285:0,0:1,0:0,0:904,760:0
1 10015 . A . 60.04 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.19;MQ0=238 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:30.04:0,30,301:985,850:0,0:1,0:0,0:0
1 10016 . C . 72.03 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.99;MQ0=235 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:42.04:0,42,427:2,1:1024,852:0,0:1,0:0
1 10017 . C . 84.05 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=8.37;MQ0=232 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:54.06:0,54,534:0,2:1100,912:0,0:0,0:0
1 10018 . C . 108.02 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=8.87;MQ0=224 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:78.03:0,78,757:0,0:1167,978:0,1:2,0:0
1 10019 . T . 96.05 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=10.24;MQ0=219 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:66.05:0,66,646:1,0:1,0:1,0:1258,1090:0
1 10020 . A . 65.97 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=9.74;MQ0=221 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:35.97:0,36,331:1309,1150:0,0:1,1:0,0:0
1 10021 . A . 65.34 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=8.14;MQ0=228 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:35.35:0,35,489:1339,1179:3,0:0,0:1,0:0
1 10022 . C . 92.98 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.79;MQ0=229 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:62.99:0,63,590:0,1:1389,1188:0,1:0,0:0
1 10023 . C . 98.93 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.69;MQ0=227 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:68.94:0,69,636:2,2:1453,1242:0,0:1,2:0
1 10024 . C . 98.95 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.46;MQ0=227 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:68.96:0,69,620:1,3:1497,1302:1,0:3,2:0
</code></pre>

<p>Is there a way for me to add <code>.</code> into the VCF header as a tag for all of the appropriate fields so that I can bypass this problem? I know from reading online that the <code>.</code> means that value is unknown. I would like to figure out how to instruct GATK to simply accept it regardless of the fact that it cannot be found in the VCF header.</p>

<p>Also, I am open to other ways I can liftover this genome to hg38. Below is the command I am using to do so using GATK.</p>

<p><code>java -jar ~/work/progs/gatk-4.0.12.0/gatk-package-4.0.12.0-local.jar LiftoverVcf -I AltaiNea.hg19_1000g.concat.LowQualRemoved.vcf -O AltaiNea.hg38_1000g.concat.LowQualRemoved.vcf -C hg19ToHg38.over.chain -R hg38.fa --REJECT rejectedRecords.vcf</code></p>

CC BY-SA 4.0
2020-02-11T17:21:57.443Z
You can easily get the header of the VCF printed into a text file using bcftools view -h file.vcf > new_header.txt , then manually add the INFO filed to the header following the required format (have a look at the VCF format [specification](https://samtools.github.io/hts-specs/VCFv4.2.pdf)), and then use bcftools reheader to get it replaced into the VCF file. 

Providing the line at position 1:121387974 would be helpfull if you require help on how to build the new INFO line that you need in the new header
JRodrigoF
<vcf><vcftools>
VCF's unknown ('.') values causing problems for GATK's Liftover Vcf
# VCF's unknown ('.') values causing problems for GATK's Liftover Vcf

(Asked by: username_0 on 2020-02-10)

I am having a tough time calling LiftoverVcf in GATK. I have concatenated all of the Vcfs of interest and removed rows with problematic values but now when I run LiftoverVCF I get the following error:
Intel; Inflater: Intel; Provider GCS is available; Picard version: Version:4.0.12.0
INFO 2020-02-10 14:36:03 LiftoverVcf Loading up the target reference genome.
INFO 2020-02-10 14:36:16 LiftoverVcf Lifting variants over and sorting (not yet writing the output file.)

[Mon Feb 10 14:59:31 EST 2020] picard.vcf.LiftoverVcf done. Elapsed time: 23.50 minutes.
Runtime.totalMemory()=7414480896
To get help, see http://broadinstitute.github.io/picard/index.html#GettingHelp
java.lang.IllegalStateException: Key . found in VariantContext field INFO at 1:121387974 but this key isn't defined in the VCFHeader. We require all VCFs to have complete VCF headers by default.
at htsjdk.variant.vcf.VCFEncoder.fieldIsMissingFromHeaderError(VCFEncoder.java:202)
at htsjdk.variant.vcf.VCFEncoder.write(VCFEncoder.java:141)
at htsjdk.variant.variantcontext.writer.VCFWriter.add(VCFWriter.java:248)
at picard.vcf.LiftoverVcf.rejectVariant(LiftoverVcf.java:456)
at picard.vcf.LiftoverVcf.doWork(LiftoverVcf.java:357)
at picard.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:295)
at org.broadinstitute.hellbender.cmdline.PicardCommandLineProgramExecutor.instanceMain(PicardCommandLineProgramExecutor.java:25)
at org.broadinstitute.hellbender.Main.runCommandLineProgram(Main.java:160)
at org.broadinstitute.hellbender.Main.mainEntry(Main.java:203)
at org.broadinstitute.hellbender.Main.main(Main.java:289)


Not sure why I am getting this error other than there may be a . in one of the info fields. Here is what the first several rows of my VCF looks like minus the header fields:
#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT AltaiNea
1 10001 . T . 51.05 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=6.32;MQ0=242 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:21.05:0,21,265:1,2:0,1:1,0:116,129:2
1 10002 . A . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:6.01:0,6,69:171,184:0,9:0,0:0,2:0
1 10003 . A . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:6.02:0,6,72:222,201:1,0:0,0:0,8:0
1 10004 . C . 39.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.61;MQ0=247 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:9.02:0,9,97:0,1:268,211:0,0:0,1:0
1 10005 . C . 41.99 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.31;MQ0=246 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:12:0,12,119:0,0:341,287:0,0:0,0:0
1 10006 . C . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:6.02:0,6,72:0,1:408,347:0,0:2,0:0
1 10007 . T . 39.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.21;MQ0=246 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:9.02:0,9,97:0,0:0,0:0,0:506,451:0
1 10008 . A . 33.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.05;MQ0=247 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:3.01:0,3,40:547,507:0,0:0,0:0,0:0
1 10009 . A . 36.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.31;MQ0=248 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:6.02:0,6,70:600,534:0,1:0,0:0,1:0
1 10010 . C . 42.01 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=4.72;MQ0=244 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:12.02:0,12,125:0,0:649,547:0,1:1,0:0
1 10011 . C . 51.02 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=5.12;MQ0=242 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:21.03:0,21,209:0,2:732,612:0,1:0,0:0
1 10012 . C . 44.99 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=3.94;MQ0=243 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:14.99:0,15,141:0,3:804,657:0,0:6,1:0
1 10013 . T . 57.04 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.20;MQ0=238 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:27.04:0,27,285:0,0:1,0:0,0:904,760:0
1 10015 . A . 60.04 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.19;MQ0=238 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:30.04:0,30,301:985,850:0,0:1,0:0,0:0
1 10016 . C . 72.03 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.99;MQ0=235 GT:DP:GQ:PL:A:C:G:T:IR 0/0:249:42.04:0,42,427:2,1:1024,852:0,0:1,0:0
1 10017 . C . 84.05 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=8.37;MQ0=232 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:54.06:0,54,534:0,2:1100,912:0,0:0,0:0
1 10018 . C . 108.02 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=8.87;MQ0=224 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:78.03:0,78,757:0,0:1167,978:0,1:2,0:0
1 10019 . T . 96.05 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=10.24;MQ0=219 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:66.05:0,66,646:1,0:1,0:1,0:1258,1090:0
1 10020 . A . 65.97 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=9.74;MQ0=221 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:35.97:0,36,331:1309,1150:0,0:1,1:0,0:0
1 10021 . A . 65.34 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=8.14;MQ0=228 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:35.35:0,35,489:1339,1179:3,0:0,0:1,0:0
1 10022 . C . 92.98 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.79;MQ0=229 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:62.99:0,63,590:0,1:1389,1188:0,1:0,0:0
1 10023 . C . 98.93 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.69;MQ0=227 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:68.94:0,69,636:2,2:1453,1242:0,0:1,2:0
1 10024 . C . 98.95 . AC=0;AF=0.00;AN=2;DP=250;DS;MQ=7.46;MQ0=227 GT:DP:GQ:PL:A:C:G:T:IR 0/0:250:68.96:0,69,620:1,3:1497,1302:1,0:3,2:0

Is there a way for me to add . into the VCF header as a tag for all of the appropriate fields so that I can bypass this problem? I know from reading online that the . means that value is unknown. I would like to figure out how to instruct GATK to simply accept it regardless of the fact that it cannot be found in the VCF header.
Also, I am open to other ways I can liftover this genome to hg38. Below is the command I am using to do so using GATK.
java -jar ~/work/progs/gatk-4.0.12.0/gatk-package-4.0.12.0-local.jar LiftoverVcf -I AltaiNea.hg19_1000g.concat.LowQualRemoved.vcf -O AltaiNea.hg38_1000g.concat.LowQualRemoved.vcf -C hg19ToHg38.over.chain -R hg38.fa --REJECT rejectedRecords.vcf

**Tags:** vcf, vcftools
> **Comments:**
> **username_1**: You can easily get the header of the VCF printed into a text file using bcftools view -h file.vcf > new_header.txt , then manually add the INFO filed to the header following the required format (have a look at the VCF format [specification](https://samtools.github.io/hts-specs/VCFv4.2.pdf)), and then use bcftools reheader to get it replaced into the VCF file.   Providing the line at position 1:121387974 would be helpfull if you require help on how to build the new INFO line that you need in the new header  

---

## 1 answers

### Answer by username_0 on 2020-02-11. Score: 2 | Accepted answer

My problem was solved using [--ALLOW-MISSING-FIELDS-IN-HEADER](https://gatk.broadinstitute.org/hc/en-us/articles/360037226512-LiftoverVcf-Picard-#--ALLOW_MISSING_FIELDS_IN_HEADER).


---

