VegaGraphs.jl

Create beatiful and interactive visualizations for graphs using Vega-Lite
Popularity
16 Stars
Updated Last
2 Years Ago
Started In
December 2020
VegaGraphs Logo

Coverage Build Status

VegaGraphs implements graph visualization with Vega-Lite.

This library is built on top of the JuliaGraphs project.

Example of Usage

The use of VegaGraphs is very straightforward. At the moment, the package has one main function called graphplot() that is shipped with all the possible modifications one can the do the graph visualization.

# Creating a Random Graph with SimpleWeightedGraphs
incidence = rand([0,1],10,20)
m = incidence'*incidence
m[diagind(m)] .= 0.0
g = SimpleWeightedGraph(m)
random_nodecolor = rand([1,2,3],20)
random_nodesize  = rand(20)
# Using VegaGraphs to create the Plot
p = VegaGraphs.graphplot(g,
    tooltip=true,  # Iteractive tooltips
    ew=true,       # VegaGraphs calculate the edge weights based on the number of time the pair appears in the graph
    node_label=false,
    node_colorfield=random_nodecolor,
    node_sizefield=random_nodesize,
    node_sizefieldtype="q",
    node_colorfieldtype="o"
)
Graph Plot

Desired Features

  • Graph visulization with interactivity;
  • Generate graph from DataFrame and generate graph from provided nodes and edges;
  • Allow to tweak node size, node color, node shape, edge size;
  • Plot degree distribution;
  • Interactivity between related graphs (e.g. papers vs authors networks);
  • Interactivity between Plot and Graph (e.g. Degree distribution and Graph);
  • IMPLEMENT DIRECTED GRAPHS AFTER UNDIRECTED