Skip to content

Prefixed genotype phasing #1932

@pd3

Description

@pd3

As reported in bcftools samtools/bcftools#2422 (comment), there is a problem with the new prefixing of partially phased genotypes, likely introduced by b14fffb4

I believe the intention was to explicitly prefix half-phased genotypes such as /0/1|2. The prefix is wrong in /0|1 (if anything, it should be |0|1, but no, it should not be prefixed in this case).

A copy-and-paste test case to reproduce the problem

printf '##fileformat=VCFv4.5\n##FORMAT=<ID=GT,Number=1,Type=String,Description="">\n##contig=<ID=chr6>\n#CHROM\tPOS\tID\tREF\tALT\tQUAL\tFILTER\tINFO\tFORMAT\taaa\nchr6\t160136611\t.\tC\tT\t.\t.\t.\tGT\t0|0\n' | bcftools view -o rmme1.bcf --write-index

printf '##fileformat=VCFv4.3\n##FORMAT=<ID=GT,Number=1,Type=String,Description="">\n##contig=<ID=chr6>\n#CHROM\tPOS\tID\tREF\tALT\tQUAL\tFILTER\tINFO\tFORMAT\tbbb\nchr6\t160136611\t.\tC\tT\t.\t.\t.\tGT\t0|1\n' | bcftools view -o rmme2.bcf --write-index

bcftools merge rmme1.bcf rmme2.bcf

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions