Closed twaddlac closed 2 years ago
This is because the -n M
refer to something else. Here the major allele means the allele observed more frequently in the population, not among the reads in that specific sample. I updated the usage page to make this clear. Also added a new --new-gt X
option which allows to do what you want, filling in the allele with the bigger read depth as determined from FORMAT/AD.
Hi @pd3,
+setGT does not allow the use of X in custom genotypes, eg --new-gt c:'0/M' is acceptable, but c:'0/X' causes the following error:
Could not parse the genotype: c:0/X
Could this capability be added?
@JosephLalli This is now available, see https://github.com/samtools/bcftools/issues/2065
I am trying to manually set a genotype based on Variant Allele Frequency (VAF) cutoffs.
Given the following VCF file:
when I run:
bcftools +setGT sample1.flt.norm.vcf.gz -- --target-gt q --new-gt M --include "VAF>0.6"
I would expect to see the genotype at position
1630
to be1/1
instead of0/0
sinceREF=C
,ALT=A
, andVAF=0.791139
.Does this make sense or is there something I'm missing?
Thank you!