GWAS + 选择进化 代码

发布时间 2023-11-29 17:58:55作者: 萧飒
library(CMplot)
library(tidyverse)


fst = choose.files()
pi = choose.files()

fst1 = read.table(fst, header = T)
head(fst1)
fst2 = fst1 %>% select(1,2,3,6) %>% top_frac(0.05,wt = MEAN_FST)
head(fst2)
write.table(fst2,"fst_vasuclar.txt",quote = F,row.names = F,sep = "\t")


pi1 = read.table(pi, header = T)
head(pi1)
pi2 = pi1 %>% select(1,2,3,5) %>% top_frac(0.05,wt = PI)
head(pi2)
write.table(pi2,"pi2_vasuclar.txt",quote = F,row.names = F,sep = "\t")