Closed MingLi-929 closed 1 year ago
This PR add two new methods to plot venn. The first is to use ggvenn to plot, which can only four sets in maximun.
ggvenn
files <- getSampleFiles() library(TxDb.Hsapiens.UCSC.hg19.knownGene) txdb <- TxDb.Hsapiens.UCSC.hg19.knownGene peakAnnoList <- lapply(files, annotatePeak, TxDb=txdb,tssRegion=c(-3000, 3000)) genes <- lapply(peakAnnoList, function(i) as.data.frame(i)$geneId) vennplot(genes,by = "ggvenn")
As the picture above, the list has 5 elements ,but only 4 Sets are plotted, which prove the limit of ggvenn
We introduced ggVennDiagram to solve this problem.
ggVennDiagram
vennplot(genes,by = "ggVennDiagram")
We can also make full use of the robust function of ggVennDiagram to adjust details in the picture.
vennplot(genes,by = "ggVennDiagram",label_percent_digit = 2)
since the ggVennDiagram use ggplot2 grammmer, we can use ggplot2 to adjust the picture
vennplot(genes,by = "ggVennDiagram",label_percent_digit = 2) + scale_fill_distiller(palette = "RdBu")
This PR add two new methods to plot venn. The first is to use
ggvenn
to plot, which can only four sets in maximun.As the picture above, the list has 5 elements ,but only 4 Sets are plotted, which prove the limit of
ggvenn
We introduced
ggVennDiagram
to solve this problem.We can also make full use of the robust function of
ggVennDiagram
to adjust details in the picture.since the
ggVennDiagram
use ggplot2 grammmer, we can use ggplot2 to adjust the picture