Question: bcftools annotate picks one attribute but not another
0
gravatar for RamRS
21 months ago by
RamRS24k
Houston, TX
RamRS24k wrote:

Hello,

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 \
-c "INFO/LIB_AC:=INFO/AC" \
-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 • 753 views
ADD COMMENTlink modified 21 months ago • written 21 months ago by RamRS24k
2
gravatar for RamRS
21 months ago by
RamRS24k
Houston, TX
RamRS24k 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 21 months ago by RamRS24k
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: 1150 users visited in the last hour