Trouble running vcf2bam jvarkit tool
1
0
Entering edit mode
4.2 years ago

I am trying to use the tool called vcf2bam from jvarkit on a server and I have the following 2 files: GRCh38_latest_genomic.fna - the file is of format FASTQ , and 00-common_all.vcf. I used samtools faidx and also picard CreateSequenceDictionary, but when I try to run the following command: $ java -jar jvarkit/dist/vcf2bam.jar -R GRCh38_latest_genomic.fna 00-common_all.vcf

I get the following errors:

[SEVERE][VcfToBam]Sequence Dictionary missing in VCF

java.io.IOException: Sequence Dictionary missing in VCF

    at com.github.lindenb.jvarkit.tools.misc.VcfToBam.run(VcfToBam.java:144)
    at com.github.lindenb.jvarkit.tools.misc.VcfToBam.doWork(VcfToBam.java:416)
    at com.github.lindenb.jvarkit.util.jcommander.Launcher.instanceMain(Launcher.java:760)
    at com.github.lindenb.jvarkit.util.jcommander.Launcher.instanceMainWithExit(Launcher.java:923)
    at com.github.lindenb.jvarkit.tools.misc.VcfToBam.main(VcfToBam.java:434)

[INFO][Launcher]vcf2bam Exited with failure (-1)

Has anyone here encountered this and managed to solve this problem?

jvarkit vcf2bam vcf picard • 1.6k views
ADD COMMENT
0
Entering edit mode

hello guys i am just trying to convert vcf file to bam file how did you use that VCF2BAM jvarkit
can you show me example

ADD REPLY
0
Entering edit mode

The command is in original question:

$ java -jar jvarkit/dist/vcf2bam.jar -R GRCh38_latest_genomic.fna 00-common_all.vcf
ADD REPLY
0
Entering edit mode
4.2 years ago

The error is "Sequence Dictionary missing in VCF"

Your VCF is missing the required lines starting with "##contig=" (see "Contig field format" in https://samtools.github.io/hts-specs/VCFv4.2.pdf).

You can ad it with picard UpdateVcfSequenceDictionary : https://broadinstitute.github.io/picard/command-line-overview.html#UpdateVcfSequenceDictionary

ADD COMMENT

Login before adding your answer.

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