学习笔记--GWAS

进行GWAS:提取出合格的样本和SNP后,使用plink进行GWAS分析

输入文件:
1、 test.ped
test.ped
The PED file is a white-space (space or tab) delimited file: the first six columns are mandatory:

 Family ID
 Individual ID
 Paternal ID
 Maternal ID
 Sex (1=male; 2=female; other=unknown)
 Phenotype

2、test.map
test.map
each line of the MAP file describes a single marker and must contain exactly 4 columns:

 chromosome (1-22, X, Y or 0 if unplaced)

 rs# or snp identifier

 Genetic distance (morgans)

 Base-pair position (bp units)
  1. 将整理好的输入文件放入plink工作路径下

  2. cmd进入plink工作目录(dir可查看目录信息)

  3. 在plink目录运行:plink.exe --ped test.ped --map test.map --maf 0.05 --assoc
    在这里插入图片描述

  4. 在工作路径可查看结果文件:plink.assoc
    plink.assoc
    整理数据—gwasResults.txt
    gwasResults.txt

结果展示:

1、曼哈顿图
在这里插入图片描述
2、QQ图:在这里插入图片描述

#install.packages("qqman")

library(qqman)
setwd("D:/Software/R/projects/GWAS")
pdf(file = 'manhattan.pdf', width=15)
rt=read.table("gwasResults.txt",header=T)
manhattan(rt, chr="CHR", bp ="BP", p="P", snp="SNP", col=c("blue4", "orange3"), ylim = c(0, 10),suggestiveline = F, genomewideline = -log10(3e-06))#临界值=0.05/snp数
dev.off()

# `QQplot`
pdf(file = 'QQplot.pdf', width=13)
qq(rt$P)
dev.off()

SNP注释: http://wannovar.usc.edu/

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

优异c

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值