Graph layouts


Do not manually instantiate this class using the class constructor. Instantiate the class using the method create_layout().

class noesis.layout.Layout(layout, *args)

This class implements the interface for network layouts. These algorithms compute visual coordinates for each node to obtain a more pleasant visualization of the network.

  • layout (string) – Technique used to compute the layout. Currently supported techniques are ‘Random’, ‘KamadaKawai’, ‘FruchtermanReingold’, ‘Hierarchical’, ‘Linear’, ‘Mesh’, ‘Radial’, BinaryTree’, ‘Circular’, ‘Hypercube’, ‘Star’, and ‘Toroidal’.
  • args (parameters) – Parameters for the layout algorithm. These parameters are specific for each algorithm and more details are provided in NOESIS documentation.

Compute a layout for a given network.

Parameters:network (Network) – Network for which the layout will be computed.
  • x (ndarray, shape (num_nodes,)) – Vector of x coordinates for each node.
  • y (ndarray, shape (num_nodes,)) – Vector of y coordinates for each node.