Split plink files from multiallelic to biallelic
0
0
Entering edit mode
5 months ago
MAPK ★ 1.8k

I have plink (bed, bim, and fam) files with multiallelic variants. I was wondering if there is a way to split the multiallelic to biallelic in plink without going back to vcf and splitting them?

Plink • 357 views
ADD COMMENT
0
Entering edit mode

The premise of your question is wrong: bed + bim + fam CANNOT store regular multiallelic variants. The plink2 (pgen + pvar + psam) format can.

Please revise your question, and provide a few lines of example data to clarify what you are talking about.

ADD REPLY
0
Entering edit mode

@chrchang523 My question is specifically about .bim file. For example, the third row is multiallelic. I just want them to split in two rows? Can I only split .bim file and keep other files as is without causing any trouble ?

1       chr1:930939:G:A 0       930939  G       A
1       chr1:930947:G:A 0       930947  A       G
1       chr1:930952:G:A;chr1:930952:G:C 0       930952  A       G

and get something like this:

1       chr1:930939:G:A 0       930939  G       A
1       chr1:930947:G:A 0       930947  A       G
1       chr1:930952:G:A 0       930952  A       G
1       chr1:930952:G:C 0       930952  A       G
ADD REPLY
1
Entering edit mode

You lost all but the two most common alleles when you imported the multiallelic variant from a VCF into plink 1.9. You need to backtrack to your VCF and redo everything from there, and you probably want to use plink 2.0 and —pfile/—make-pgen instead of plink 1.9 —bfile/—make-bed.

ADD REPLY
0
Entering edit mode

hy chrchang i have to make pgen and psam file and after that --pca and got plink.eigenvec but it's now creating a problem in the R package for PCA grapgh

ADD REPLY

Login before adding your answer.

Traffic: 965 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