This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Help getting Plink files into Treemix

Does anyone know how to get Plink data into Treemix? I want to try out the program, but the manual does not indicate how to convert Plink files into Treemix files.

Anyone with experience with this?

plink snp

Not sure if helpful, but the wiki page has:

...
...

3/12/12:
Added a small script to convert stratified allele frequencies output from plink into TreeMix format. 
This will be incorporated into the next release, but for the moment must be downloaded 
separately. To run this, let's say you have data in plink format (e.g., data.bed, data.bim, 
data.fam) and a plink cluster file matching each individual to a population (data.clust).

Now you run:
plink --bfile data --freq --missing --within data.clust
gzip plink.frq
plink2treemix.py plink.frq.gz treemix.frq.gz

1 answer

I just saw this question. I have added a plink import, it is one line in glactools:

glactools bplink2acf --fai reference.fai [PLINK prefix] |  glactools acf2treemix -  |gzip > treemix.gz

Log in to answer this question.