Since you are in R, consider using the UpsetR library. It doesn't make Venn diagrams but it helps to visualize overlaps between any number of groups.

http://gehlenborglab.org/research/projects/upsetr/#:~:text=UpSetR%20is%20an%20R%20package,based%20on%20groupings%20and%20queries.

Answer from swbarnes2 on Stack Exchange
🌐
CRAN
cran.r-project.org › web › packages › eulerr › vignettes › venn-diagrams.html
Venn diagrams with eulerr - CRAN - R Project
April 20, 2026 - It might not be as easy on the eye, but at least will be interpreted correctly. eulerr only supports diagrams for up to 5 sets. Part of the reason is practical. eulerr is built around ellipses and ellipses are only good for Venn diagrams with at most 5 sets. The other part of the reason has ...
Top answer
1 of 2
2

Since you are in R, consider using the UpsetR library. It doesn't make Venn diagrams but it helps to visualize overlaps between any number of groups.

http://gehlenborglab.org/research/projects/upsetr/#:~:text=UpSetR%20is%20an%20R%20package,based%20on%20groupings%20and%20queries.

2 of 2
0

You might consider different ways of using the venneuler package. I'm not super thrilled with its usability (or with the accuracy of the overlaps), but you can get it to make custom Venn diagrams.

Here is a thread with some suggestions along these lines.

Below is some sample R code that I slightly modified from an old project that I used to make a 3-category Venn diagram.

I didn't run this to make sure that it works because of an irritating Java dependency issue on my OSX laptop that I don't feel like fixing right now, but as long as you have a JDK on your machine and can install the packages it should work.

# note irritating rJava dependency of venneuler
library(plotrix)
library(venneuler)

#A-B sharing: 200414
#B-C sharing: 17561
#A-C sharing: 16764
#All share 14201

# get coordinates for circles- replace as needed
# this function is supposed to plot stuff, but doesn't actually
ven = venneuler(c(C=48147-17561-16764+14201, 
                  B=347181-17561-200414+14201, 
                  A=325971-200414-16764+14201, 
                  "C&B"=17561, "B&A"=200414, "C&A"=16764, "A&B&C"=14201))

cats = c('A','B','C')

# note- this following only shows up in the .pdf printer, not in the X11 utility plotter
pdf('venn.pdf')
plot(c(-.5,1.5), c(-.5,1.5), type='n', xaxt='n', yaxt='n', bty='n', xlab='', ylab='')
draw.circle(ven$center[1,1], ven$center[1,2], ven$diameters[1],
        col = hsv(1,1,1,.5))
draw.circle(ven$center[2,1], ven$center[2,2], ven$diameters[2], 
            col = hsv(.5,1,1,.5))
draw.circle(ven$center[3,1], ven$center[3,2], ven$diameters[3],
            col = hsv(.1,1,1,.5))

text(ven$center[1,1]+.065, ven$center[1,2], labels=cats[3], cex=1.3)
text(ven$center[2,1], ven$center[2,2]-.2, labels=cats[2], cex=1.3)
text(ven$center[3,1], ven$center[3,2]+.2, labels=cats[1], cex=1.3)

dev.off()
🌐
Rdrr.io
rdrr.io › cran › eulerr › man › plot.euler.html
plot.euler: Plot Euler and Venn diagrams in eulerr: Area-Proportional Euler and Venn Diagrams with Ellipses
May 29, 2024 - rdrr.io Find an R package R language docs Run R in your browser ... Browse all... ... Plot diagrams fit with euler() and venn() using grid::Grid() graphics. This function sets up all the necessary plot parameters and computes the geometry of the diagram. plot.eulergram(), meanwhile, does the ...
🌐
Andrew Wheeler
andrewpwheeler.com › 2015 › 07 › 21 › venn-diagrams-in-r-with-some-discussion
Venn diagrams in R (with some discussion!) | Andrew Wheeler
January 4, 2018 - The other day I had a set of three separate categories of binary data that I wanted to visualize with a Venn diagram (or a Euler) diagram of their intersections. I used the venneuler R package and it worked out pretty well. library(venneuler) MyVenn
🌐
CRAN
cran.r-project.org › web › packages › eulerr › vignettes › gallery.html
A Gallery of Euler and Venn Diagrams
completely_contained <- euler(c( "A" = 15, "B" = 15, "C" = 0, "A&B" = 3, "A&C" = 0, "B&C" = 0, "A&B&C" = 3 )) plot( completely_contained, labels = list(col = c("white", "black", "black")), edges = list(col = "white", lex = 2), fills = c("black", "cyan", "orange") ) intersecting_inside <- euler(c( "A" = 15, "B" = 0, "C" = 0, "A&B" = 3, "A&C" = 3, "B&C" = 0, "A&B&C" = 2 )) plot( intersecting_inside, fills = list( fill = c( "lavenderblush2", "lightblue2", "lightsalmon", "orange", "steelblue4", "white", "plum2" ) ), legend = list(side = "right") )
🌐
BMC Bioinformatics
bmcbioinformatics.biomedcentral.com › articles › 10.1186 › 1471-2105-12-35
VennDiagram: a package for the generation of highly-customizable Venn and Euler diagrams in R | BMC Bioinformatics | Full Text
January 26, 2011 - To fill this gap we introduce VennDiagram, an R package that enables the automated generation of highly-customizable, high-resolution Venn diagrams with up to four sets and Euler diagrams with up to three sets.
🌐
Rdrr.io
rdrr.io › cran › eulerr › man › venn.html
venn: Venn diagrams in eulerr: Area-Proportional Euler and Venn Diagrams with Ellipses
May 29, 2024 - # The trivial version f1 <- venn(5, names = letters[1:5]) plot(f1) # Using data (a numeric vector) f2 <- venn(c(A = 1, "B&C" = 3, "A&D" = 0.3)) # The table method venn(pain, factor_names = FALSE) # Using grouping via the 'by' argument through the data.frame method venn(fruits, by = list(sex, age)) # Using the matrix method venn(organisms) # Using weights venn(organisms, weights = c(10, 20, 5, 4, 8, 9, 2)) # A venn diagram from a list of sample spaces (the list method) venn(plants[c("erigenia", "solanum", "cynodon")]) eulerr documentation built on May 29, 2024, 1:35 a.m. ... Package overview README.md A Gallery of Euler and Venn Diagrams eulerr under the hood Introducing eulerr Loss Functions Venn diagrams with eulerr Visualizing Euler diagrams with eulerr
🌐
CRAN
cran.r-project.org › web › packages › VennDiagram › VennDiagram.pdf pdf
VennDiagram: Generate High-Resolution Venn and Euler ...
Creates a Venn diagram with three sets. Creates Euler diagrams when the dataset meets certain
Find elsewhere
🌐
CRAN
cran.r-project.org › web › packages › eulerr › eulerr.pdf pdf
Area-Proportional Euler and Venn Diagrams with Ellipses
May 8, 2026 - Micallef L, Rodgers P. eulerAPE: Drawing Area-Proportional 3-Venn Diagrams Using Ellipses.
🌐
CRAN
cran.r-project.org › web › packages › eulerr › vignettes › introduction.html
Introducing eulerr
April 20, 2026 - eulerr generates area-proportional euler diagrams that display set relationships (intersections, unions, and disjoints) with circles, ellipses, or axis-aligned rectangles and squares. Euler diagrams are Venn diagrams without the requirement that all set interactions be present (whether they ...
🌐
CRAN
cran.r-project.org › package=eulerr
eulerr: Area-Proportional Euler and Venn Diagrams with Ellipses
April 21, 2026 - An Euler diagram is a generalization of a Venn diagram, relaxing the criterion that all interactions need to be represented. Diagrams may be fit with ellipses and circles via a wide range of inputs and can be visualized in numerous ways.
🌐
GitHub
github.com › uclahs-cds › package-VennDiagram
GitHub - uclahs-cds/package-VennDiagram: Generate High-Resolution Venn and Euler Plots · GitHub
VennDiagram is a R package for generating high-resolution, customizable Venn diagrams with up to four sets and Euler diagrams with up to three sets.
Starred by 8 users
Forked by 2 users
Languages   R
🌐
R Project
search.r-project.org › CRAN › refmans › eulerr › html › plot.euler.html
R: Plot Euler and Venn diagrams
fit <- euler(c("A" = 10, "B" = 5, "A&B" = 3)) # Customize colors, remove borders, bump alpha, color labels white plot(fit, fills = list(fill = c("red", "steelblue4"), alpha = 0.5), labels = list(col = "white", font = 4)) # Add quantities to the plot plot(fit, quantities = TRUE) # Add a custom legend and retain quantities plot(fit, quantities = TRUE, legend = list(labels = c("foo", "bar"))) # Plot without fills and distinguish sets with border types instead plot(fit, fills = "transparent", lty = 1:2) # Save plot parameters to plot using some other method diagram_description <- plot(fit) # Plots using 'by' argument plot(euler(fruits[, 1:4], by = list(sex)), legend = TRUE)
🌐
Jolars
jolars.github.io › eulerr › reference › plot.euler.html
Plot Euler and Venn diagrams — plot.euler • eulerr
Defaults for these values, as well ... using eulerr_options(). If the diagram has been fit using the data.frame or matrix methods and using the by argument, the plot area will be split into panels for each combination of the one to two factors. For users who are looking to plot their diagram using another package, all the necessary parameters can be collected if the result of this function ...
🌐
Rdrr.io
rdrr.io › cran › eulerr › man › euler.html
euler: Area-proportional Euler diagrams in eulerr: Area-Proportional Euler and Venn Diagrams with Ellipses
April 21, 2026 - rdrr.io Find an R package R language docs Run R in your browser ... Browse all... ... Fit Euler diagrams (a generalization of Venn diagrams) using numerical optimization to find exact or approximate solutions to a specification of set relationships.
🌐
Bio-spring
venn.bio-spring.top › intro
Chapter 2 Introduction | Venn Diagram cookbook in R
A Venn diagram must contain all \(2^n\) logically possible zones of overlap between its \(n\) curves, representing all combinations of inclusion/exclusion of its constituent sets. ... a named numeric vector with set combinations as disjoint set combinations or unions (depending on how the argument type is set in euler()), a matrix or data frame of logicals with columns representing sets and rows the set relationships for each observation, a list of sample spaces, or a table.
🌐
Rdrr.io
rdrr.io › cran › venneuler › man › venneuler.html
venneuler: Calculates Venn and Euler Diagram in venneuler: Venn and Euler Diagrams
May 29, 2024 - rdrr.io Find an R package R language docs Run R in your browser ... Browse all... ... vd <- venneuler(c(A=0.3, B=0.3, C=1.1, "A&B"=0.1, "A&C"=0.2, "B&C"=0.1 ,"A&B&C"=0.1)) plot(vd) # same as c(A=1, `A&B&C`=1, C=1) m <- data.frame(elements=c("1","2","2","2","3"), sets=c("A","A","B","C","C")) v <- venneuler(m) plot(v) m <- as.matrix(data.frame(A=c(1.5, 0.2, 0.4, 0, 0), B=c(0 , 0.2, 0 , 1, 0), C=c(0 , 0 , 0.3, 0, 1))) # without weights v <- venneuler(m > 0) plot(v) # with weights v <- venneuler(m) plot(v)
🌐
Medium
medium.com › @lanabojanic › high-resolution-venn-diagram-in-r-d93d4f9f08e4
High-resolution Venn diagram in R | by Lana Bojanić | Medium
November 8, 2023 - library(grid) library(eulerr) tiff("test1.tiff", units="in", width=7, height=5, res=700) VennDiag <- euler(c("Drug and alcohol services" = 312, "Mental health services" = 380, "Drug and alcohol services&Mental health services" = 116)) plot(VennDiag, quantities = FALSE, labels = FALSE, fills= list(fill=c("#5CACEE", "#36648B"), alpha=1), main = "", edges=list(lex=1.5)) grid::grid.text(substitute(paste(bold("Drug and alcohol\n services\n 312 (39%)"))), x=0.20, y=0.445, gp=gpar(col="#262626", fontsize=16)) grid::grid.text(substitute(paste(bold("116 (14%)"))), x=0.475, y=0.445, gp=gpar(col="#262626", fontsize=16)) grid::grid.text(substitute(paste(bold("Mental health\n services\n 380 (47%)"))), x=0.755, y=0.445, gp=gpar(col="white", fontsize=16)) dev.off()
🌐
Jolars
jolars.github.io › eulerr
Area-Proportional Euler and Venn Diagrams with Ellipses • eulerr
eulerr generates area-proportional Euler diagrams that display set relationships (intersections, unions, and disjoints) with circles or ellipses. Euler diagrams are Venn diagrams without the requirement that all set interactions be present (whether ...