使用GCTA软件进行GWAS分析
001、
root@PC1:/home/test# ls gwas_test.bed gwas_test.bim gwas_test.fam root@PC1:/home/test# awk '{print $1, $2, $6}' gwas_test.fam > phenotype.txt ## 表型数据 root@PC1:/home/test# plink --bfile gwas_test --pca 3 1> /dev/null ## pca协变量 root@PC1:/home/test# ls gwas_test.bed gwas_test.bim gwas_test.fam phenotype.txt plink.eigenval plink.eigenvec plink.log ## G矩阵 root@PC1:/home/test# /home/software/gcta_v1.94.0Beta_linux_kernel_3_x86_64/gcta_v1.94.0Beta_linux_kernel_3_x86_64_static --bfile gwas_test --make-grm --make-grm-alg 1 --out gmat 1> /dev/null root@PC1:/home/test# ls gmat.grm.bin gmat.grm.N.bin gwas_test.bed gwas_test.fam plink.eigenval plink.log gmat.grm.id gmat.log gwas_test.bim phenotype.txt plink.eigenvec ## 稀疏矩阵 root@PC1:/home/test# /home/software/gcta_v1.94.0Beta_linux_kernel_3_x86_64/gcta_v1.94.0Beta_linux_kernel_3_x86_64_static --grm gmat --make-bK-sparse 0.05 --out gmat2 1> /dev/null root@PC1:/home/test# ls gmat2.grm.id gmat2.log gmat.grm.id gmat.log gwas_test.bim phenotype.txt plink.eigenvec gmat2.grm.sp gmat.grm.bin gmat.grm.N.bin gwas_test.bed gwas_test.fam plink.eigenval plink.log ## gwas分析 root@PC1:/home/test# /home/software/gcta_v1.94.0Beta_linux_kernel_3_x86_64/gcta_v1.94.0Beta_linux_kernel_3_x86_64_static --bfile gwas_test --grm-sparse gmat2 --fastGWA-mlm --pheno phenotype.txt --qcovar plink.eigenvec --out result 1> /dev/null root@PC1:/home/test# ls gmat2.grm.id gmat2.log gmat.grm.id gmat.log gwas_test.bim phenotype.txt plink.eigenvec result.fastGWA gmat2.grm.sp gmat.grm.bin gmat.grm.N.bin gwas_test.bed gwas_test.fam plink.eigenval plink.log result.log root@PC1:/home/test# head -n 5 result.fastGWA CHR SNP POS A1 A2 N AF1 BETA SE P 1 snp1 2802 G T 541 0.0988909 1.2972 7.79033 0.867753 1 snp2 2823 T C 541 0.0628466 4.77428 9.37217 0.610465 1 snp3 4512 G A 541 0.0665434 8.79444 9.16059 0.337041 1 snp4 16529 T C 541 0.0545286 2.06676 10.1066 0.837966 root@PC1:/home/test# head -n 5 result.fastGWA | column -t ## 结果文件 CHR SNP POS A1 A2 N AF1 BETA SE P 1 snp1 2802 G T 541 0.0988909 1.2972 7.79033 0.867753 1 snp2 2823 T C 541 0.0628466 4.77428 9.37217 0.610465 1 snp3 4512 G A 541 0.0665434 8.79444 9.16059 0.337041 1 snp4 16529 T C 541 0.0545286 2.06676 10.1066 0.837966
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 震惊!C++程序真的从main开始吗?99%的程序员都答错了
· 【硬核科普】Trae如何「偷看」你的代码?零基础破解AI编程运行原理
· 单元测试从入门到精通
· 上周热点回顾(3.3-3.9)
· winform 绘制太阳,地球,月球 运作规律
2021-07-31 linux系统中scp命令实现服务器之间数据的传输
2021-07-31 SRA Toolkit的下载安装及使用
2021-07-31 NCBI中sra数据的下载
2018-07-31 linux 系统 grep 命令