Questions tagged [graphviz]

Graphviz, developed by AT&T Research Labs, is the leading application for layout and drawing of graphs (objects comprised of vertices connected by edges). It includes the dot language, a complete syntax for graph description and a set of layout engines. Graphviz is free and open source.

Graphviz, developed by AT&T Research Labs, is the leading application for the layout and drawing of graphs (objects comprised of vertices connected by edges). It includes the dot language -- a complete syntax for graph description -- and a set of layout engines. Graphviz is free and open source.

Useful Graphviz Resources

Related Tags

2917 questions
39
votes
3 answers

Does the DOT language support variables / aliases?

I'm trying to print out a directed graph, and I keep changing various node attributes such as color and shape. Is there some way to use a variable which is defined once and used for multiple nodes? Ideally I'd like something like this: digraph g {…
Shep
  • 7,990
  • 8
  • 49
  • 71
38
votes
3 answers

graph rendering in python (flowchart visualization)

to visualize a sequence of nodes connected by edges encoded in python. looking for a python library to visualize such graph data. either a library written in python or python bindings, is ok (i am aware of Visustin, but looking for alternatives)
eWizardII
  • 1,916
  • 4
  • 32
  • 55
38
votes
5 answers

Improve positioning of subscript and superscript on node labels

When using both subscript and superscripts on a node label, is it possible to alter the positioning so that they are directly above each other. Example: digraph G { x11[label=1(1)>]; …
user2957945
  • 2,353
  • 2
  • 21
  • 40
38
votes
3 answers

How to set default node shape to box instead of oval?

I have some long labels in my graph written in dot language. As a result, (the default shape being oval) I have some not very practical thin really long oval in my graph which take much space. I would like to set the default shape to box for all my…
Stephane Rolland
  • 38,876
  • 35
  • 121
  • 169
36
votes
1 answer

how to change default font size for graphviz?

I use doxygen + graphviz for documenting my code. graphviz does a nice job of generating images. Is there any way to change the default fontsize for graphviz? The default is 14, but I want to use 12 instead. Its a real pain to change the fontsize…
chronodekar
  • 2,616
  • 6
  • 31
  • 36
36
votes
3 answers

graphviz drawing graph vertically

I am using graphviz to draw directed graphs . Now thing is that although I am able to generate graph correctly the graph is designed horizontally which is not according to my requirements . So, how can I draw directed graphs vertically Please help…
user2060673
  • 459
  • 1
  • 4
  • 8
36
votes
3 answers

Graphviz outputs a mess

I'm trying to visualise the following data in dot format using GraphViz: digraph n { node [nodesep=2.0, fontsize=11]; graph [ overlap=false]; edge[weight=0.2]; A -> B [label="I/5"] A -> A [label="*/0"] A -> C [label="ii/2"] A -> H…
Ivy
  • 3,393
  • 11
  • 33
  • 46
35
votes
3 answers

How does one define double-lines for edge and node shapes in graphviz dot?

How can edges and nodes be styled using graphviz dot with doubled lines as shown the in the "LEGAL" and "TAX DISC" nodes of the following diagram?
Judge Maygarden
  • 26,961
  • 9
  • 82
  • 99
34
votes
1 answer

How to control subgraphs' layout in dot?

i have a digraph composed of many independant and simple subgraphs of various sizes. dot lays all these subgraphs horizontally, so i end up with a 40000x200 output file, e.g: G1 G2 G3 G.....4 G5 How do i tell dot to layout these subgraphs in both…
Benoît
  • 3,355
  • 2
  • 29
  • 34
34
votes
3 answers

Graphviz graph positioning xlabels

I have tried using xlp and also followed this graphviz thread (http://www.graphviz.org/content/how-use-xlp-attribute-positioning-external-labels-xlabel), but neither have actually worked. This is my dot code: digraph { forcelabels=true; …
user1634494
  • 609
  • 1
  • 7
  • 23
33
votes
5 answers

GraphViz - How to have a subgraph be left-to-right when main graph is top-to-bottom?

I have a graph file like this: digraph { "Step1" -> "Step2" -> "Step3"; subgraph step2detail { "Step2" -> "note1"; "Step2" -> "note2"; "Step2" -> "note3"; "Step2" -> "note4"; rankdir=TB } } I want…
Amandasaurus
  • 58,203
  • 71
  • 188
  • 248
33
votes
1 answer

Forcing orthogonal (vertical or horizontal) edges with dot

I would like to force dot displaying only vertical or horizontal edges between nodes. I have found a similar request with the post Family tree layout with Dot/GraphViz, but I am not dealing with trees, so I hope there is a solution without inserting…
nocbos
  • 391
  • 1
  • 4
  • 6
33
votes
4 answers

Automatic multiline labels in Graphviz?

I'm using Graphviz to draw some graphs. I'm using labels on nodes and I can put in "\n" to force it to split the label across 2 lines. Is there some way to get Graphviz (or dot which I'm using) to automatically see that it should split some nodes…
Amandasaurus
  • 58,203
  • 71
  • 188
  • 248
32
votes
1 answer

Graphviz .dot node ordering

I'm building a epsilon NFA to recognize a regular expression using the canonical construction. I'm using subgraphs to group various parts of the regular expression. The * operator is giving me particular trouble since dot has decided to move the…
Michael Conlen
  • 1,959
  • 2
  • 17
  • 19
32
votes
4 answers

How can I control within level node order in graphviz's dot?

I have a graph that has a tree as its backbone. So I have, for example a node A with children B, C, and D. Assuming the graph is being drawn top-down, A will be on one level, then B, C, and D. I would like to force graphviz to lay them out in B,…
Robert P. Goldman
  • 860
  • 1
  • 8
  • 16