Best/more standard graph representation file format? (GraphSON, Gexf, GraphML? )
Asked Answered
M

4

24

What's the standard graph representation file format or otherwise the most used one? I would say one of these three:

but it would be great if anyone could point out the advantages/weaknesses from each of them.

More answered 9/7, 2015 at 14:50 Comment(1)
It might be good to remove "Best" from the question as this is highly subjective and hard to quantify. Answering the 'most popular', 'most supported', or 'most standard' is somewhat easier even when context dependent. You cay say "The standard format in field X is Y and is used by 70% of new projects", but trying to attach a quality to Y is harder.Unclear
S
9

The answer ultimately lies with the size of your problem and what your are trying to achieve.

For example, none of those formats can handle billions of vertices whereas some dedicated large-scale graph analytics frameworks such as Spark or GraphLab-Create can.

GraphML and GEXF are roughly equivalent, both XML based. GraphML is standard and supported in a lot of graph librairies such as NetworkX, igraph, Boost Graph Library, Graph-tool, JGraphT, Gephi. GraphSon is not popular.

To draw your GraphML or GEXF graphs, you can use Gephi or Tulip (GEXF only).

Skyscraper answered 9/7, 2015 at 17:34 Comment(2)
So isn't there any popular alternative based in JSON instead of XML?More
Not really, every library defines its own JSON format. NetworkX, sigma.js and graphson are all JSON format but different.Skyscraper
A
9

I think JGF is a good candidate here too.

I evaluated a lot for a recent project and this came out on top. Specifically, I liked:

  • Trivial to parse and generate
  • Able to include arbitrary extra data for any node, edge, or graph.
  • Well specified, and can be parsed by more than one existing project.

http://jsongraphformat.info/

https://github.com/jsongraph/json-graph-specification

Alimentation answered 17/9, 2016 at 5:9 Comment(0)
J
6

Ideally you want something supported by major third-party software. I'm currently looking into exporting to Gephi, and it supports:

  • GEXF
  • GDF
  • GML
  • GraphML
  • Pajek NET
  • GraphViz DOT
  • CSV
  • UCINET DL
  • Tulip TPL
  • Netdraw VNA

I'd love to see an analysis of the benefits of each format. Gephi's sample datasets includes a lot of GEXF and GML.

Joktan answered 6/3, 2018 at 16:5 Comment(1)
+1 for CSV which respects the Unix Philosophy. If you need anything more, write your own script that converts to the other thing (that may never gain traction anyway).Lucrece
P
2

GNU Bison outputs Graphviz DOT files to help visualize the parser automaton, which usually are very big graphs. Here you can find a small sample.

I think that DOT is a de-facto standard at least for for open source projects, also because there are many excellent open source tools for producing images from DOT files (e.g. dot, neato, sfdp).

At the moment i'm writing this, Gephi and Tulip don't plot edges labels, which could be a problem for some applications.

Photoelasticity answered 1/6, 2019 at 17:40 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.