convert vcf to r/qtl

103 views
Skip to first unread message

J H

unread,
Feb 28, 2022, 4:37:21 PM2/28/22
to R/qtl discussion
I want to identify genotyping errors. (book chapter 3.5). I have a vcf file, how do I convert this file to qtl format like data(hyper) in the book. Thanks
The parents are BN_LX and SHR
My vcf file is like this:
##fileformat=VCFv4.2
...
#CHROM        POS        ID        REF        ALT        QUAL        FILTER        INFO        FORMAT        BN-Lx_Cub_mRatNor1        BN_male_mRatNor1        BXH10_mRatNor1        BXH11_mRatNor1        BXH12_mRatNor1
chr12        258        chr12_258_C_A        C        A        23        .        AF=0.416667;AQ=23;ANN=A|intergenic_region|MODIFIER|CHR_START-Zar1l|CHR_START-Zar1l|intergenic_region|CHR_START-Zar1l|||n.258C>A||||||        GT:DP:AD:GQ:PL:RNC        0/0:24:17,7:21:0,0,0:..        ./.:7:5,2:4:0,9,2:II        ./.:46:20,24:3:0,14,0:II        0/0:39:14,24:27:0,0,0:..        ./.:37:10,25:17:0,27,17:II
chr12        269        chr12_269_C_T        C        T        31        .        AF=0.444444;AQ=31;ANN=T|intergenic_region|MODIFIER|CHR_START-Zar1l|CHR_START-Zar1l|intergenic_region|CHR_START-Zar1l|||n.269C>T||||||        GT:DP:AD:GQ:PL:RNC        1/1:38:29,9:7:11,11,0:..        ./.:17:13,3:5:0,10,3:II        0/0:76:60,12:1:0,1,0:..        ./.:69:69,0:0:32,0,1622:II        1/1:78:65,10:0:4,7,0:..
chr12        331        chr12_331_G_A        G        A        16        .        AF=0.111111;AQ=16;ANN=A|intergenic_region|MODIFIER|CHR_START-Zar1l|CHR_START-Zar1l|intergenic_region|CHR_START-Zar1l|||n.331G>A||||||        GT:DP:AD:GQ:PL:RNC        ./.:20:20,0:0:29,0,449:II        0/0:7:7,0:21:0,21,209:..        0/0:31:22,7:29:0,29,38:..        ./.:35:26,9:11:0,20,10:II        1/1:40:32,7:6:16,16,0:..

Karl Broman

unread,
Feb 28, 2022, 4:42:55 PM2/28/22
to R/qtl discussion
You might look at vcftools for extracting the genotypes. But they'd then need to be converted from 0/1/2 where 0=major allele
to codes that are based on the two parental strains' genotypes. AA/AB/BB say, where A=one parent and B=other parent.


karl
Reply all
Reply to author
Forward
0 new messages