Change sample order

787 views
Skip to first unread message

Michael San jose

unread,
Apr 26, 2016, 8:27:46 PM4/26/16
to plink2-users
Hi everyone,

I am trying to change the sample order of my data in plink. I am trying to convert a vcf file to a bed file while changing the order.

here is what i am inputting into plink
plink2 --vcf data.vcf --make-bed --maf 0.01 --out datatobed --allow-extra-chr --indiv-sort f new_order.txt

it give me an error
Error: --indiv-sort file does not contain all loaded sample IDs.

But all the sample names are in the new_order.txt 

the new_order.txt file has two columns with a space between them with the sample names in the order I want it in.

Any ideas whats wrong?

Mike

Christopher Chang

unread,
Apr 26, 2016, 8:31:43 PM4/26/16
to plink2-users
Hi,

What do the sample IDs look like in your VCF file?  You may need to use a different mix of --double-id/--const-fid/--id-delim (see https://www.cog-genomics.org/plink2/input#double_id ) to get plink to see the correspondence between the VCF IDs and the new_order.txt IDs.

Michael San jose

unread,
Apr 26, 2016, 10:23:39 PM4/26/16
to plink2-users
The ids are just two letters and then a number "ms1320"

Anahit Hovhannisyan

unread,
Jun 29, 2017, 3:59:21 AM6/29/17
to plink2-users
Hey! Michael, I have the same problem now with error notification. Have you managed to resolve this problem?

среда, 27 апреля 2016 г., 6:23:39 UTC+4 пользователь Michael San jose написал:
Reply all
Reply to author
Forward
0 new messages