Question: Recode to VCF with -a2-allele flag in PLINK
gravatar for emyli
3.4 years ago by
emyli10 wrote:

Hi there,

I generated a VCF using plink from .ped and .map files from a genotyping experiment as so:

plink --file test --recode vcf --out testVCF

As is well documented, this assigned the REF alleles in the output VCF to be the major allele observed in the data.

I am trying to recode to make the VCF assign the correct REF allele as so:

plink --vcf testVCF --a2-allele reference_alleles.txt --recode vcf --out testVCF_corrected

I am met with the error:

--a2-allele: 0 assignments made.

I have tried formatting the reference_alleles.txt as:


exm77264    G
exm77266    C
exm77274    T



G   exm77264
C   exm77266
T   exm77274

As well as specifiying:

--a2-allele reference_alleles.txt  1 2


--a2-allele reference_alleles.txt  1 2

Any advice would be greatly appreciated, thanks!

recode plink vcf • 3.2k views
ADD COMMENTlink modified 3.2 years ago by Biostar ♦♦ 20 • written 3.4 years ago by emyli10

Hmm, the only way you should get "0 assignments made" is if the variant IDs in reference_alleles.txt don't match those in What do the first lines of look like? Can you post the full .log file from a failing --a2-allele run?

ADD REPLYlink modified 3.4 years ago • written 3.4 years ago by chrchang5237.7k

yes, but since the vcf option is being used then the variant IDs should be assigned in the VCF file itself.

ADD REPLYlink written 2.8 years ago by asif.zubair0
Please log in to add an answer.


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