Skip to content

bcftools merge irregularly creates negative AD values when alt alleles don't match between files #2244

@happ-m

Description

@happ-m

In trying to merge 2+ vcf files output from bcftools call where the goal is to genotype a fixed list of positions, I have ran into a handful of negative allelic depth values in the output. In trying to narrow down the root cause, it appears as though this happens if the alternate allele is not the same across files. Including when there is no alternate allele in one file but it is present in another.

The behavior also appears to be very inconsistent in a couple of ways.

  1. sometimes it replaces the initial GT call for that sample to ./.
  2. in trying to create some small example files to provide, one of the positions I had identified as problematic in the larger dataset no longer generated negative values when merging using the subsetted data.

You will find two small datasets ( A & B) that when merged, create negative AD values at variant position 1:6070233.

Happy to provide larger datasets privately that captures the range of issues I am seeing. I am using v1.2.0

A.vcf.gz
B.vcf.gz
Merged.vcf.gz

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions