d3Network

Christopher Gandrud

Tools for creating D3 JavaScript directed network graphs from R.



Minimal Example

Click the image to see a working example:

This is the code to create the graph:

# Create fake data
Source <- c("A", "A", "A", "A", "B", "B", "C", "C", "D")
Target <- c("B", "C", "D", "J", "E", "F", "G", "H", "I")
NetworkData <- data.frame(Source, Target)

# Make network graph 
d3SimpleNetwork(NetworkDatad3, height = 300, width = 700)

Many more examples can be found on the package's main page.


Installation

You can install d3Network using the devtools package and the following code:

devtools::install_github("d3Network", "christophergandrud")