Note that by default only links between adjacent genomes are computed and shown. Set gggenomes(..., adjacent_only=TRUE) to compute and show all links between all genomes.

geom_link(
  mapping = NULL,
  data = links(),
  stat = "identity",
  position = "identity",
  na.rm = FALSE,
  show.legend = NA,
  inherit.aes = TRUE,
  offset = 0.15,
  ...
)

Arguments

offset

distance between seq center and link start. Use two values c(<offset_top>, <offset_bottom>) for different top and bottom offsets

Examples

p <- gggenomes(seqs=emale_seqs, links = emale_ava) + geom_seq()
p + geom_link()

# change offset from seqs
p + geom_link(aes(fill=de, color=de), offset = 0.05) +
  scale_fill_viridis_b() + scale_colour_viridis_b()

# combine with flip
p %>% flip(3,4,5) + geom_link()

# compute & show all links among all genomes (not recommended for large dataset)
gggenomes(links=emale_ava, adjacent_only = FALSE) + geom_link()
#> No seqs or feats provided, inferring seqs from links