Question: bcftools annotate picks one attribute but not another
gravatar for RamRS
2.6 years ago by
Houston, TX
RamRS27k wrote:


I've run into a weird error and would like to figure out what's going on.

I'm annotating a VCF file from a library VCF file using bcftools annotate. I'm picking AC and AF fields from the library VCF file, and annotating them as a modified tag. This works fine for AF, but does not work for AC. My command is:

bcftools annotate -a library.vcf.gz \
-h library.vcfheader \
-Ov  input_vcf

When I substitute all AC above with AF above, annotations happen fine. For the same entry that the AF annotation is seen, AC is not annotated even though the library file has both AC and AF for that matching (CHROM,POS,ID,REF and ALT matching) entry.

What am I missing here? Does bcftools crap out if the annotation sub-tag picked out is the first annotation sub-tag (aka doesn't have a ; in front)?

I'm using bcftools v1.6

EDIT: I ran a few more tests.

I tried another attribute (AN) and it works fine. It's only AC that doesn't. And when I don't do the mapping(not -c INFO/LIB_AC:=INFO/AC, only -c INFO/AC), the AC rightly replaces the AC in my VCF. It's just unable to work in the way specific above. Really specific, really weird.

bcftools vcf annotate • 1.0k views
ADD COMMENTlink modified 2.6 years ago • written 2.6 years ago by RamRS27k
gravatar for RamRS
2.6 years ago by
Houston, TX
RamRS27k wrote:

Did some more debugging, tried a bunch of changes and this is what worked:

The datatype on the header file was wrong. It was Float instead of Integer, and changing that made it work. Really weird, but I'll stop complaining.

ADD COMMENTlink written 2.6 years ago by RamRS27k
Please log in to add an answer.


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