Note

This documents the development version of NetworkX. Documentation for the current release can be found here.

jit_data(G, indent=None, default=None)[source]

Returns data in JIT JSON format.

Parameters
GNetworkX Graph
indent: optional, default=None

If indent is a non-negative integer, then JSON array elements and object members will be pretty-printed with that indent level. An indent level of 0, or negative, will only insert newlines. None (the default) selects the most compact representation.

default: optional, default=None

It will pass the value to the json.dumps function in order to be able to serialize custom objects used as nodes.

Returns
data: JIT JSON string

Deprecated since version 2.6: ..