This is the official development repository for BCFtools. See installation instructions and other documentation here http://samtools.github.io/bcftools/howtos/install.html
I have a vcf file that has some variants assigned multiple IDs. For example:
chr11_KI270721v1_random 78026 c11_pos2000643;rs72849239 G A .PASS . GT:GQ 0/0:5 ./.:. 0/0:4 ./.:. ./.:. ./.:. ./.:../.:. ./.:. ./.:.
I wish to query this vcf with a file containing snp ids. This works fine except that variants with multiple identifiers are not included in the output. To illustrate the issue:
A 'testid' file with c11_pos2000643.outputs nothing with the following command:
bcftools query -f"%POS" -i'ID=@testid' merged.vcf.gz
No output with direct ID equal comparision:
bcftools query -f"%POS" -i'ID=="c11_pos2000643"' merged.vcf.gz
This works and returns the position:
bcftools query -f"%POS" -i'ID~"c11_pos2000643"' merged.vcf.gz
Essentially, is it possible to use similarity/subset operator ~ with a snp list? If not, how I may be able to query the records with multiple IDs?
Hello,
I have a vcf file that has some variants assigned multiple IDs. For example:
chr11_KI270721v1_random 78026 c11_pos2000643;rs72849239 G A .PASS . GT:GQ 0/0:5 ./.:. 0/0:4 ./.:. ./.:. ./.:. ./.:../.:. ./.:. ./.:.
I wish to query this vcf with a file containing snp ids. This works fine except that variants with multiple identifiers are not included in the output. To illustrate the issue:
A 'testid' file with c11_pos2000643.outputs nothing with the following command:
bcftools query -f"%POS" -i'ID=@testid' merged.vcf.gz
No output with direct ID equal comparision:
bcftools query -f"%POS" -i'ID=="c11_pos2000643"' merged.vcf.gz
This works and returns the position:
bcftools query -f"%POS" -i'ID~"c11_pos2000643"' merged.vcf.gz
Essentially, is it possible to use similarity/subset operator
~
with a snp list? If not, how I may be able to query the records with multiple IDs?I am working with Bcftools version 1.20
Thank you.