ties <- data.frame(
from = c("A", "A", "B", "C", "D", "F", "F", "E"),
to = c("B", "C", "D", "E", "E", "E", "G", "G"),
stringsAsFactors = FALSE)
coords <- layout_tbl_graph_layered(ties, times = 6)
coords
Run the code above in your browser using DataLab