Notice:
If you happen to see a question you know the answer to, please do chime in and help your fellow community members. We encourage our fourm members to be more involved, jump in and help out your fellow researchers with their questions. GATK forum is a community forum and helping each other with using GATK tools and research is the cornerstone of our success as a genomics research community.We appreciate your help!

Test-drive the GATK tools and Best Practices pipelines on Terra


Check out this blog post to learn how you can get started with GATK and try out the pipelines in preconfigured workspaces (with a user-friendly interface!) without having to install anything.

Error running VariantFiltration GATK4: java.lang.NumberFormatException

I'm trying to hard filter my VCF files with VariantFiltration, however I keep getting an empty file. I checked the log, the same error message keeps appearing (see below). This looks like there's a problem reading the file.

I've tried the same command on VCF files that I have successfully run through VaraintFiltration before, same error.
It also doesn't seem to be a problem with the current file, since ValidateVariants runs without error. The file doesn't seem to be the problem.

Any ideas about what's causing the error?

Command
cd /path/to/gatk

java -Xmx3g -jar gatk-package-4.0.4.0-local.jar VariantFiltration \ -R path/ref.fasta \ -V path/input.vcf \ -O path/out.vcf \ --filter-expression "DP < 88 || QD < 20 || FS > 0.25 || SOR >1.5 || MQ < 60 || MQRankSum < 0" \ --filter-name snp_filter

Error Message
Runtime.totalMemory()=2007498752 java.lang.NumberFormatException: For input string: "0.12" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) at java.lang.Long.parseLong(Long.java:589) at java.lang.Long.parseLong(Long.java:631) at org.apache.commons.jexl2.JexlArithmetic.toLong(JexlArithmetic.java:906) at org.apache.commons.jexl2.JexlArithmetic.compare(JexlArithmetic.java:718) at org.apache.commons.jexl2.JexlArithmetic.lessThan(JexlArithmetic.java:774) at org.apache.commons.jexl2.Interpreter.visit(Interpreter.java:967) at org.apache.commons.jexl2.parser.ASTLTNode.jjtAccept(ASTLTNode.java:18) at org.apache.commons.jexl2.Interpreter.visit(Interpreter.java:1283) at org.apache.commons.jexl2.parser.ASTOrNode.jjtAccept(ASTOrNode.java:18) at org.apache.commons.jexl2.Interpreter.visit(Interpreter.java:1274) at org.apache.commons.jexl2.parser.ASTOrNode.jjtAccept(ASTOrNode.java:18) at org.apache.commons.jexl2.Interpreter.visit(Interpreter.java:1274) at org.apache.commons.jexl2.parser.ASTOrNode.jjtAccept(ASTOrNode.java:18) at org.apache.commons.jexl2.Interpreter.visit(Interpreter.java:1274) at org.apache.commons.jexl2.parser.ASTOrNode.jjtAccept(ASTOrNode.java:18) at org.apache.commons.jexl2.Interpreter.visit(Interpreter.java:1274) at org.apache.commons.jexl2.parser.ASTOrNode.jjtAccept(ASTOrNode.java:18) at org.apache.commons.jexl2.Interpreter.interpret(Interpreter.java:232) at org.apache.commons.jexl2.ExpressionImpl.evaluate(ExpressionImpl.java:65) at htsjdk.variant.variantcontext.JEXLMap.evaluateExpression(JEXLMap.java:186) at htsjdk.variant.variantcontext.JEXLMap.get(JEXLMap.java:95) at htsjdk.variant.variantcontext.JEXLMap.get(JEXLMap.java:15) at htsjdk.variant.variantcontext.VariantContextUtils.match(VariantContextUtils.java:338) at org.broadinstitute.hellbender.tools.walkers.filters.VariantFiltration.matchesFilter(VariantFiltration.java:380) at org.broadinstitute.hellbender.tools.walkers.filters.VariantFiltration.filter(VariantFiltration.java:339) at org.broadinstitute.hellbender.tools.walkers.filters.VariantFiltration.apply(VariantFiltration.java:299) at org.broadinstitute.hellbender.engine.VariantWalkerBase.lambda$traverse$0(VariantWalkerBase.java:110) at java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:184) at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:175) at java.util.Iterator.forEachRemaining(Iterator.java:116) at java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1801) at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481) at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471) at java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:151) at java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:174) at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) at java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:418) at org.broadinstitute.hellbender.engine.VariantWalkerBase.traverse(VariantWalkerBase.java:108) at org.broadinstitute.hellbender.engine.GATKTool.doWork(GATKTool.java:892) at org.broadinstitute.hellbender.cmdline.CommandLineProgram.runTool(CommandLineProgram.java:134) at org.broadinstitute.hellbender.cmdline.CommandLineProgram.instanceMainPostParseArgs(CommandLineProgram.java:179) at org.broadinstitute.hellbender.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:198) 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)

Best Answer

Answers

Sign In or Register to comment.