schmidtpaul / sankeyd3plus Goto Github PK
View Code? Open in Web Editor NEWD3 JavaScript Sankey Diagrams in R
Home Page: https://schmidtpaul.github.io/sankeyD3plus/
License: GNU General Public License v3.0
D3 JavaScript Sankey Diagrams in R
Home Page: https://schmidtpaul.github.io/sankeyD3plus/
License: GNU General Public License v3.0
It would be nice to have
fontSize
should also affect the xAxisDomain
NodeID
and xAxisDomain
sinksRight = TRUE
from networkD3::sankeyNetwork()
links <- data.frame(
source = c(0, 0, 0, 1, 2),
target = c(1, 2, 3, 4, 4)
)
sankeyD3plus::sankeyNetwork(
Links = links,
Source = "source",
Target = "target",
fontSize = 30,
nodePadding = 30,
xAxisDomain = c("One", "Two", "Three")
)
Created on 2023-08-03 with reprex v2.0.2
links <- data.frame(
source = c(0, 0, 1, 2),
target = c(1, 2, 3, 3),
value = c(10, 20, 10, 20)
)
nodes <- data.frame(
label = c("I am using \n in this string",
"I am using \r in this string",
"I am using <br> in this string",
"I am using
in this string")
)
sankeyD3plus::sankeyNetwork(
Links = links,
Nodes = nodes,
Source = "source",
Target = "target",
Value = "value",
NodeID = "label",
xAxisDomain = c("Hello\nWorld", "Hello
World", "Hello<br>World")
)
Created on 2023-08-03 with reprex v2.0.2
URL <- paste0(
"https://cdn.rawgit.com/christophergandrud/networkD3/",
"master/JSONdata/energy.json")
Energy <- jsonlite::fromJSON(URL)
networkD3::sankeyNetwork(Links = Energy$links, Nodes = Energy$nodes, Source = "source",
Target = "target", Value = "value", NodeID = "name",
units = "TWh", fontSize = 12, nodeWidth = 30,
sinksRight = TRUE)
sankeyD3plus::sankeyNetwork(Links = Energy$links, Nodes = Energy$nodes, Source = "source",
Target = "target", Value = "value", NodeID = "name",
units = "TWh", fontSize = 12, nodeWidth = 30,
NodeGroup = "name")
Created on 2023-08-03 with reprex v2.0.2
The Examples page should have examples for
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.