Question: Hapmap to vcf
0
gravatar for shinken123
23 days ago by
shinken12360
México
shinken12360 wrote:

Hi all,

I have a hapmap file from tassel and I want to convert it to a vcf. Tassel can convert the file but takes the major allele as the reference and the minor as the alternative.

I want to use the reference genome for the reference alleles and set the alleles different from the reference genome as the alternative. I also tried GATK but it gives me the error NULL alleles are not supported.

My hapmap file looks like this and is tab deleimited:

rs# alleles chrom   pos strand  assembly#   center  protLSID    assayLSID   panelLSID   QCcode  sample1 sample2 sample3 sample4 sample5 sample6 sample7 
S1_134  C/T 1   134 +   N   N   N   N   N   N   C   C   C   N   N   C   C   
S1_204  G/A 1   204 +   N   N   N   N   N   N   G   G   R   N   N   G   G   
S1_340  C/T 1   340 +   N   N   N   N   N   N   C   C   C   N   N   C   C   
S1_477  C/T 1   477 +   N   N   N   N   N   N   C   C   Y   N   C   C   C

There is a tool to perform what I want?

Best,

Eric

convert hapmap vcf • 86 views
ADD COMMENTlink modified 22 days ago by RamRS18k • written 23 days ago by shinken12360

I want to use the reference genome for the reference alleles and set the alleles different from the reference genome as the alternative.

You can correct this using bcftools +fixref:

$ bcftools +fixref input.vcf -Ov -o output.vcf -- -f genome.fa -m flip

fin swimmer

ADD REPLYlink written 21 days ago by finswimmer6.0k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1873 users visited in the last hour