I have a multilevel Sankey diagram made in R with package GoogleVis and I would like to be able to control the distance between nodes. According to https://developers.google.com/chart/interactive/docs/gallery/sankey to adjust node distance we can use nodePadding
Here an example:
dat <- data.frame(From=c(rep("A",3), rep("B", 3),rep("X", 2), rep("Y", 2),rep("Z", 2)),
To=c(rep(c("X", "Y", "Z"),2), rep(c("F","G"), 3)),
Weight=c(5,7,6,2,9,4,2,5,3,13,4,6))
p1 <- gvisSankey(dat, from="From", to="To", weight="Weight",
options=list(sankey="{node:{nodePadding:100}}"))
plot(p1)
However, I would like to have my nodes X,Y and Z together (nodePadding:0) and the orders at 100. Is this possible?