This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Plink v1.9: Order of SNPs when extracting from file

Hello everyone.

I think I have a fairly simple question but my search engine efforts have been unsuccessful.

I recently started working with plink (v1.9) and I'm using it to get a correlation matrix between a list of SNPs. The command I use is:

plink --bfile <relevant bfile> --extract <txt document with list of snps> --r square gz --write-snplist --out <output>

Assume that my SNP text file holds the following (fake) SNPs in CHR:BP format: 1:11, 1:9, 1:13

The contents of the text file generated by --write-snplist: 1:9, 1:11, 1:13.

I want the columns of my output to be the names of the SNPs I used. My question is: will the columns of the correlation matrix be in the order of the --extract file or the --write-snplist file?

Thank you.

plink

1 answer

Practically all plink output commands (including both --write-snplist and --r) are based on the variant order in the input .bim file.

Log in to answer this question.