upset_plot | R Documentation |
This function constructs an "upset plot" showing patterns of gene familiy presence/absence in order of pattern frequency (number of gene families following the pattern). The genomes are ordered along their phylogeny.
upset_plot(
tg,
genome_name = genome,
genome_col = NULL,
genome_bold = NULL,
color_scale = scale_color_brewer(palette = "Paired", guide = "none"),
n = 50,
freq_min = NULL,
barchart_height = 50,
frequency_labels = F,
phylogroups = F
)
tg |
A tidygenomes object |
genome_name |
Name of a variable (unquoted) from the genome or phylogroup table that should be used to name the genomes |
genome_col |
Name of a variable (unquoted) from the genome or phylogroup table that should be used to color the genome names |
genome_bold |
Name of a logical variable (unquoted) from the genome or phylogroup table that indicates which genome names should be in bold |
color_scale |
Ggplot color scale generated by a scale_color_... type function |
n |
The number of presence/absence patterns to plot |
freq_min |
The minimum frequency of patterns to appear on the plot |
barchart_height |
The relative height of the frequency barchart, expressed as a number of rows from the main plot |
frequency_labels |
Logical variable indicating whether the frequency numbers should be plotted as labels on top of the barchart |
phylogroups |
Should horizontal lines be plotted between phylogroups? |
A ggplot object
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.