What is a graph?
Graph theory is a mathematical discipline that studies networks of nodes and links or edges connecting them. Graphs are useful for many applications: social media networks, streets connecting cities, transfers connecting bank accounts or networks of people, addresses, bank accounts and cars connected via insurance claims and events. We’ll deal with some of those applications later on when discussing the application of network and graph paradigms to visualizing fraudulent actions.
Which libraries have I examined?
The internet is full, I mean literally FULL of libraries to display networked graphs. I had to choose some and discard others. First I decided to neglect commercial libraries that don’t have an open source edition. Then I stopped evaluating libs when I recognized that the documentation is too poor or functionality too limited to further investigate. So here is the list in alphabetical order:
- Cytoscape with Cola.js rendering
- D3.js with Cola.js rendering
- Infovis Toolkit
Libraries I didn’t evaluate due to licensing constraints:
Libraries I gave up on:
- Dracula Graph Library (Graph Dracula … you understand … haha)
Needs a raphael.js renderer to display custom node shapes. Too much fuzz for a very short test.
Poorly documented. Didn’t succeed to build a test candidate in short (!) time.
How did I test?
I always used the same test network. It consists of 6 nodes and 6 edges. Some edges are red and one node is green. The nodes are labelled “Node 1” to “Node 6”. Colouring and labelling is used to test how easy it is to insert some basic customization into the layout.
On the right side you can see a hand drawn (well not really handdrawn) picture of the demo network. The examples I present are fully functional, not screen shots and I will briefly go through the source code.
The first part for Alchemy.js can be found here.
The second post on Arbor.js is here.
The third part with Cytoscape.js and Cola.js is here.
The fourth part with D3 is here.