Question: GATK VariantFiltration NumberFormatException
0
gravatar for ajaypaulsharma
14 months ago by
ajaypaulsharma0 wrote:

Hi,

I am trying to filter a vcf file Info column. I have some Info Fields with values "DP=.". When I try to use GATK VariationFilter tool with option -filter "DP>50", it throws error: java.lang.NumberFormatException for input string ".". This is the case with many other values in INFO Column in vcf file. I also tried using -filter "DP!='.' && DP>50". How can I overcome this issue?

Thanks! Ajay

ADD COMMENTlink modified 14 months ago by Brice Sarver3.5k • written 14 months ago by ajaypaulsharma0
0
gravatar for Brice Sarver
14 months ago by
Brice Sarver3.5k
United States
Brice Sarver3.5k wrote:

The GATK is particularly sensitive to type, and you can get weird results if you try to mix-and-match among them. Perhaps the more relevant question is why your DP fields are ''. If you don't have a depth of at least 1, how do you have any evidence for that site to potentially harbor a variant in the first place?

A quick workaround that should cause GATK to exit cleanly would be to replace these strings with DP=0, and then your filter should work. Something like sed is your friend here and will be quite fast.

ADD COMMENTlink written 14 months ago by Brice Sarver3.5k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 2108 users visited in the last hour