Problem to calculate fst by smartpca
Entering edit mode
6.3 years ago
anahit ▴ 20

Hello guys! I want to ask you about smartpca program. I want to calculate fst values. Do you know what parameters exactly to include in the parfile. I was trying to use only genotypename,snpname, indivname and fstonly (YES) but i have no results in my output. Thank you in advance!

SNP • 2.9k views
Entering edit mode
6.1 years ago
Simo ▴ 50

Hi anahit, this is what I usually do:

Open the file .fam and change the values in column 6.

You have to create groups by assigning a number to those individuals that belong to the same group, something like this:

ID1 A 0 0 1 3 
ID1 B 0 0 1 3 
ID2 C 0 0 1 4 
ID2 D 0 0 1 4

It is important that you skip the number 1 and 2 (that are recognized as case and control), and number 9 that for some reason is not well accepted!

Once you have changed the file .fam, convert the bed/bim/fam to ped/map.

Prepare your par file with the option "fstonly: YES"

Run it with smartpca.

You'll end up with a file .phy showing the Fst matrix you want.

Hope this was helpful.

Entering edit mode

Thank you so much, Simo!

Entering edit mode

Hey man. Sorry to hijack this thread so late but queries regarding this were next to nothing. I have already changed my fam file according to your recommendations and converted it with convertf. However, I am not able to generate the file with the fst data. The following is my par file:

fstonly: YES
fstdetailsname: sogdia.greek.4.out
genotypename: sogdia.greek.4.geno
snpname: sogdia.greek.4.snp
indivname: sogdia.greek.4.ind
evecoutname: sogdia.greek.4.evec
evaloutname: sogdia.greek.4.eval
numoutevec:   20
numoutlieriter: 0
snpweightoutname: sogdia.greek.4.snpweight
killr2: YES
r2thresh: 0.75
outputgroup: YES

Also if you could point me towards how to exactly plot the data. Thank you so much.


Login before adding your answer.

Traffic: 2505 users visited in the last hour
Help About
Access RSS

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6