Extracting FILTER field from gnomAD vcf file
1
0
Entering edit mode
3.4 years ago

Dear all,

My goal is to use PyVCF to process variants taken for GRCh37 and gnomAD v2.

On the gnomAD vcf file there is the filter field containing the following information:

##FILTER=<ID=AC0,Description="Allele count is zero after filtering out low-confidence genotypes (GQ < 20; DP < 10; and AB < 0.2 for het calls)">
##FILTER=<ID=InbreedingCoeff,Description="InbreedingCoeff < -0.3">
##FILTER=<ID=PASS,Description="Passed all variant filters">
##FILTER=<ID=RF,Description="Failed random forest filtering thresholds of 0.055272738028512555, 0.20641025579497013 (probabilities of being a true positive variant) for SNPs, indels">

Using PyVCF works fine for all other fields (pos, ref, alt and info). However for the filter field, for most of the variants I get the empty list:

print(variant.FILTER)
# will print: []

For a scarce amount of variants I get ['AC0', 'RF'] or ['ACO'].

Does the empty list mean that the FILTER is PASS as shown in the function: _parse_filter() in the parser code?

My installed PyVCF version is 0.6.8.

Thank you and keep safe!

vcf PyVCF gnomAD • 1.5k views
ADD COMMENT
2
Entering edit mode
3.4 years ago
Ram 43k

From the code, it does look like if PASS return [] will give you an empty array if the site is a PASS.

ADD COMMENT
0
Entering edit mode

Thank you very much! I will mark it as resolved for now.

Keep safe :)

ADD REPLY

Login before adding your answer.

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