upset-plot {ggVennDiagram} | R Documentation |
Plot a upset plot
Description
This function generate a upset plot by creating a composite plot which contains subplots generated by ggplot2.
Usage
plot_upset(
venn,
nintersects = NULL,
order.intersect.by = c("size", "name", "none"),
order.set.by = c("size", "name", "none"),
relative_height = 3,
relative_width = 0.3,
top.bar.color = "grey30",
top.bar.y.label = NULL,
top.bar.show.numbers = TRUE,
top.bar.numbers.size = 3,
sets.bar.color = "grey30",
sets.bar.show.numbers = FALSE,
sets.bar.x.label = "Set Size",
intersection.matrix.color = "grey30",
specific = TRUE,
...
)
Arguments
venn |
a class Venn object |
nintersects |
number of intersects. If NULL, all intersections will show. |
order.intersect.by |
'size', 'name', or "none" |
order.set.by |
'size', 'name', or "none" |
relative_height |
the relative height of top panel in upset plot |
relative_width |
the relative width of left panel in upset plot |
top.bar.color |
default is "grey30" |
top.bar.y.label |
default is NULL |
top.bar.show.numbers |
default is TRUE |
top.bar.numbers.size |
text size of numbers |
sets.bar.color |
default is "grey30" |
sets.bar.show.numbers |
default is FALSE |
sets.bar.x.label |
default is "Set Size" |
intersection.matrix.color |
default is "grey30" |
specific |
whether only include specific items in subsets, default is TRUE. |
... |
useless |
Value
an upset plot
Examples
list = list(A = sample(LETTERS, 20),
B = sample(LETTERS, 22),
C = sample(LETTERS, 14),
D = sample(LETTERS, 30, replace = TRUE))
venn = Venn(list)
plot_upset(venn)
plot_upset(venn, order.intersect.by = "name")
plot_upset(venn, nintersects = 6)
[Package ggVennDiagram version 1.5.2 Index]