Converting GP field in a VCF to GT
1
0
Entering edit mode
2.4 years ago
Garan ▴ 690

My VCF file is only populated with posterior genotype probabilities (GP - derived from a BGEN file) for each variant, is there any way to convert the GP field to GT (genotyped 0/0, 0/1, 1/1 or ./.)? Could anyone suggest a bit of software which can easily handle 10K odd human samples imputed with HRC v1.1?

#CHROM POS    ID     REF    ALT    QUAL   FILTER INFO   FORMAT 31610M
1      13380  1:13380 C      G      .      .      .      GP     1,0,0

to

#CHROM POS    ID     REF    ALT    QUAL   FILTER INFO   FORMAT 31610M
1      13380  1:13380 C      G      .      .      .      GT:GP     0/0:1,0,0
VCF Threshold GT GP • 1.3k views
ADD COMMENT
1
Entering edit mode
2.4 years ago
Garan ▴ 690

After abit more digging around, I found the following solution:

QCTool

qctool -g input.vcf.gz -threshold 0.9 -og output.gt.vcf.gz

https://www.well.ox.ac.uk/~gav/qctool_v2/documentation/examples/converting_genotypes.html

"the output VCF file will contain two FORMAT fields, namely GT (the threshholded call) and GP (the original imputed probabilities)".

ADD COMMENT

Login before adding your answer.

Traffic: 1550 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6