enrichplot让你们对clusterProfiler系列包无法自拔先来一段搞笑的街头卖膏药的视频,大家可以娱乐一下再继续往下看,因为我接下来就是要卖Y叔版「膏药」!大家喜欢clusterProfiler,除了功能强大、支持广泛之外,我想还有一点必须是可视化,毕竟大家都是视觉动物,颜值即正义。然而这些都是我早期的代码,我其实一直想重新写,希望可以全部用gplot2来实现,方便后续维护、更好看、更强大。而这在我博士毕业后,终于找了个时间重写了一遍,并且也加入了部分新的图形,我把这些代码重新打包,已经在Bioconductor上,叫enrichplot。有了这个包,你们更加对clusterProfiler系列包无法自拔,让其它的工具毫无颜色。Theenrichplotpackageimplementsseveralmethodsforenrichmentresultvisualizationtohelpinterpretation.Itsupportsbothhypergeometrictestandgenesetenrichmentanalysis.Bothofthemarewidelyusedtocharacterizepathway/functionrelationshipstoelucidatemolecularmechanismsfromhigh-throughputgenomicdata.TheenrichplotpackagesupportsvisualizingenrichmentresultsobtainedfromDOSE(Yuetal.2015),clusterProfiler(Yuetal.2012),ReactomePA(YuandHe2016)andmeshes.InducedGODAGgraphGeneOntology(GO)isorganizedasadirectedacyclicgraph.AninsighfulwayoflookingattheresultsoftheanalysisistoinvestigatehowthesignificantGOtermsaredistributedovertheGOgraph.ThegoplotfunctionshowssubgraphinducedbymostsignificantGOterms.library(clusterProfiler)data(geneList,package='DOSE')deabs(geneList)>2]ego'org.Hs.eg.db',ont='BP',readable=TRUE)library(enrichplot)goplot(ego)BarplotBarplotisthemostwidelyusedmethodtovisualizeenrichedterms.Itdepictstheenrichmentscores(e.g.pvalues)andgenecountorratioasbarheightandcolor.barplot(ego,showCategory=20)DotplotDotplotissimilartobarplotwiththecapabilitytoencodeanotherscoreasdotsize.Bothbarplotanddotplotsupportsfacettingtovisualizesub-ontologiessimultaneously.dotplot(ego,showCategory=30)go'org.Hs.eg.db',ont='all')dotplot(go,split='ONTOLOGY')+facet_grid(ONTOLOGY~.,scale='free')Gene-ConceptNetworkBoththebarplotanddotplotonlydisplayedmostsignificantenrichedterms,whileusersmaywanttoknowwhichgenesareinvolvedinthesesignificantterms.Thecnetplotdepictsthelinkagesofgenesandbiologicalconcepts(e.g.GOtermsorKEGGpathways)asanetwork.##removeredundentGOtermsego2cnetplot(ego2,foldChange=geneList)cnetplot(ego2,foldChange=geneList,circular=TRUE,colorEdge=TRUE)UpSetPlotTheupsetplotisanalternativetocnetplotforvisualizingthecomplexassociationbetweengenesandgenesets.Itemphasizesthegeneoverlappingamongdifferentgenesets.upsetplot(ego)Heatmap-likefunctionalclassificationTheheatplotissimilartocnetplot,whiledisplayingtherelationshipsasaheatmap.Thegene-conceptnetworkmaybecometoocomplicatedifuserwanttoshowalargenumbersignificantterms.Theheatplotcansimplifytheresultandmoreeasytoidentifyexpressionpatterns.heatplot(ego2)heatplot(ego2,foldChange=geneList)EnrichmentMapEnrichmentmaporganizesenrichedtermsintoanetworkwithedgesconnectingoverlappinggenesets.Inthisway,mutuallyoverlappinggenesetsaretendtoclustertogether,makingiteasytoidentifyfunctionalmodule.emapplot(ego2)ridgelineplotforexpressiondistributionofGSEAresultTheridgeplotwillvisualizeexpressiondistributionsofcoreenrichedgenesforGSEAenrichedcategories.Ithelpsuserstointerpretup/down-regulatedpathways.kk-gseKEGG(geneList,nPerm=10000)ridgeplot(kk)runningscoreandprerankedlistofGSEAresultRunningscoreandprerankedlistaretraditionalmethodsforvisualizingGSEAresult.Theenrichplotpackagesupportsbothofthemtovisualizethedistributionofthegenesetandtheenrichmentscore.gseaplot(kk,geneSetID=1,by='runningScore',title=kk$Description[1])gseaplot(kk,geneSetID=1,by='preranked',title=kk$Description[1])gseaplot(kk,geneSetID=1,title=kk$Description[1])ReferencesYu,Guangchuang,andQing-YuHe.2016.“ReactomePA:AnR/BioconductorPackageforReactomePathwayAnalysisandVisualization.”MolecularBioSystems12(2):477–79.doi:10.1039/C5MB00663E.Yu,Guangchuang,Li-GenWang,YanyanHan,andQing-YuHe.2012.“clusterProfiler:anRPackageforComparingBiologicalThemesAmongGeneClusters.”OMICS:AJournalofIntegrativeBiology16(5):284–87.doi:10.1089/omi.2011.0118.Yu,Guangchuang,Li-GenWang,Guang-RongYan,andQing-YuHe.2015.“DOSE:AnR/BioconductorPackageforDiseaseOntologySemanticandEnrichmentAnalysis.”Bioinformatics31(4):608–9.doi:10.1093/bioinformatics/btu684.给赞给Y叔点个赞小程序