|
source("http://www./biocLite.R") #啟動(dòng)bioconductor biocLite("clusterProfiler") #安裝clusterProfiler包 library(clusterProfiler) ##文件為一列gene entrez ID, 文件名設(shè)為 enterz.txt setwd("d:/") #設(shè)置目錄 getwd() #查看目錄 biocLite("org.Hs.eg.db") library(org.Hs.eg.db) ego <- enrichGO(OrgDb="org.Hs.eg.db", gene = genelist, ont = "CC", pvalueCutoff = 0.01, readable= TRUE) #GO富集分析 write.csv(summary(ego),"GO-enrich.csv",row.names =F) #寫入文件 ekk <- enrichKEGG(gene=
genelist,organism write.csv(summary(ekk),"KEGG-enrich.csv",row.names =F) #寫入文件 dotplot(ego,showCategory=10,title="Enrichment GO Top10") #泡泡圖 barplot(ego, showCategory=20,title="EnrichmentGO")
|
|
|