使用 emmax 进行GWAS分析


 

001、

root@PC1:/home/test# ls
gwas_test.map  gwas_test.ped
root@PC1:/home/test# plink --file gwas_test --recode 12 transpose --out emmax_format 1> /dev/null
root@PC1:/home/test# ls
emmax_format.log  emmax_format.tfam  emmax_format.tped  gwas_test.map  gwas_test.ped
root@PC1:/home/test# plink --file gwas_test --pca 3 1> /dev/null
root@PC1:/home/test# ls
emmax_format.log  emmax_format.tfam  emmax_format.tped  gwas_test.map  gwas_test.ped  plink.eigenval  plink.eigenvec  plink.log
root@PC1:/home/test# awk '{print $1, $2, $6}' gwas_test.ped > phenotype.txt
root@PC1:/home/test# awk '{print $1, $2, 1, $3, $4, $5}' plink.eigenvec > cov.file
root@PC1:/home/test# ls
cov.file          emmax_format.tfam  gwas_test.map  phenotype.txt   plink.eigenvec
emmax_format.log  emmax_format.tped  gwas_test.ped  plink.eigenval  plink.log
root@PC1:/home/test# /home/software/emmax-kin-intel64 emmax_format -v -d 10 -o emmax_kin 1> /dev/null

Reading TFAM file emmax_format.tfam ....
Memory allocated, nrows = 541, nheadercols = 6, nvaluecols = 0
Freeing cmat
Freeing cheaders
Memory freed
Identified 541 individuals from TFAM file
Setting # unit lines = 923672 to fit the memory requirement
Reading TPED file emmax_format.tped ....
Reading 0 SNPs
Reading 10000 SNPs
Reading 20000 SNPs
Reading 30000 SNPs
Reading 40000 SNPs
Reading 50000 SNPs
Reading 60000 SNPs
Reading 70000 SNPs
Reading 80000 SNPs
Reading 90000 SNPs
Reading 100000 SNPs
Succesfully finished reading TPED file
Computing kinship matrix with the remaining 101549 SNPs..
f_block_weight = 101549.000000
nex = 0
nex_call_rate = 0
OMP: Warning #72: KMP_AFFINITY: affinity only supported for Intel(R) processors.    ## AMD处理器
OMP: Warning #71: KMP_AFFINITY: affinity not supported, using "disabled".
Finished computing kinship matrix
Printing the kinship matrix to file emmax_format.

 

002、使用kin关系

root@PC1:/home/test# ls
cov.file          emmax_format.tfam  emmax_kin      gwas_test.ped  plink.eigenval  plink.log
emmax_format.log  emmax_format.tped  gwas_test.map  phenotype.txt  plink.eigenvec
root@PC1:/home/test# /home/software/emmax-intel64 -t emmax_format -o emmax_kin -p phenotype.txt -k emmax_kin
nmiss = 0 , mphenoflag = 0
OMP: Warning #72: KMP_AFFINITY: affinity only supported for Intel(R) processors.
OMP: Warning #71: KMP_AFFINITY: affinity not supported, using "disabled".
evals[0] = -0.000000, evals[1] = 1.008034, evals[n-1] = 6.654231
k = 540,  n-q = 540
root@PC1:/home/test# ls
cov.file          emmax_format.tfam  emmax_kin      emmax_kin.ps    gwas_test.map  phenotype.txt   plink.eigenvec
emmax_format.log  emmax_format.tped  emmax_kin.log  emmax_kin.reml  gwas_test.ped  plink.eigenval  plink.log
root@PC1:/home/test# head emmax_kin.ps
snp1    -1.1141 7.9858  0.8891
snp2    -5.6218 9.4275  0.55121
snp3    -8.9421 9.2048  0.33176
snp4    2.9532  10.513  0.77888
snp5    2.3625  8.9748  0.79247
snp6    -3.3411 5.1728  0.51862
snp7    -3.8305 8.1569  0.63883
snp8    0.94697 6.9264  0.8913
snp9    0.57514 6.2112  0.92626
snp10   4.5423  7.4249  0.54095

 

003、使用kin + cov协变量

root@PC1:/home/test# ls
cov.file          emmax_format.tfam  emmax_kin      emmax_kin.ps    gwas_test.map  phenotype.txt   plink.eigenvec
emmax_format.log  emmax_format.tped  emmax_kin.log  emmax_kin.reml  gwas_test.ped  plink.eigenval  plink.log
root@PC1:/home/test# /home/software/emmax-intel64 -t emmax_format -o emmax_kin_cov -p phenotype.txt -k emmax_kin -c cov.file
nmiss = 0 , mphenoflag = 0
OMP: Warning #72: KMP_AFFINITY: affinity only supported for Intel(R) processors.
OMP: Warning #71: KMP_AFFINITY: affinity not supported, using "disabled".
evals[0] = -0.000000, evals[1] = -0.000000, evals[n-1] = 2.204020
k = 537,  n-q = 537
root@PC1:/home/test# ls
cov.file           emmax_format.tped  emmax_kin_cov.ps    emmax_kin.ps    gwas_test.ped   plink.eigenvec
emmax_format.log   emmax_kin          emmax_kin_cov.reml  emmax_kin.reml  phenotype.txt   plink.log
emmax_format.tfam  emmax_kin_cov.log  emmax_kin.log       gwas_test.map   plink.eigenval
root@PC1:/home/test# head emmax_kin_cov.ps
snp1    -2.1373 7.8752  0.78619
snp2    -5.258  9.3224  0.57298
snp3    -8.9221 9.0994  0.32728
snp4    -0.49211        10.405  0.9623
snp5    4.4257  8.9895  0.6227
snp6    -2.9939 5.1511  0.56134
snp7    -4.8139 8.0663  0.5509
snp8    -0.83212        6.858   0.90347
snp9    1.8465  6.2003  0.76596
snp10   2.6951  7.3799  0.71511

 

参考:

01、https://www.jianshu.com/p/0f39ff5a7643

02、https://zhuanlan.zhihu.com/p/270092364

 

原创文章,作者:bd101bd101,如若转载,请注明出处:https://blog.ytso.com/277988.html

(0)
上一篇 2022年7月31日
下一篇 2022年7月31日

相关推荐

发表回复

登录后才能评论