Open ctb opened 3 years ago
here are some pretty pictures:
I just wanted to make a note that twice in two months, I've used upset plots of a few signatures as an alternative to containment to understand what's happening in my systems.
One of them is here: https://github.com/taylorreiter/2021-paper-metapangenomes/issues/5#issuecomment-1055688521
And one of them is here:
My workflow for making this is:
library(readr)
library(dplyr)
library(ComplexUpset)
acc_db <- "GCA_000162535.1-s__Parabacteroides_distasonis"
metabat <- read_csv(paste0("outputs/metabat2_prokka_sigs_all/", acc_db, "_all_kmers.csv"),
col_names = c("metabat"))
kmers <- read_csv(paste0("outputs/nbhd_sigs_species_all/", acc_db, "_all_kmers.csv"),
col_names = "kmers")
roary <- read_csv(paste0("outputs/roary_sigs_all/", acc_db, "_pan_genome_reference_all_genes.csv"),
col_names = "roary")
upset_df <- UpSetR::fromList(list(metabat2 = metabat$metabat,
kmers = kmers$kmers,
roary = roary$roary))
conditions <- c("metabat2", "kmers", "roary")
upset <- upset(upset_df, intersect = conditions)
adding the upset
command via the betterplot plugin in https://github.com/sourmash-bio/sourmash_plugin_betterplot/pull/35 - it produces figures like this:
this might be of use to people looking to grok genome overlaps etc.
notebook permalink notebook latest, but link may break ;)