FDP(1)

NAME
fdp - filter for drawing undirected graphs

SYNOPSIS
fdp [-Gname=value] [-Nname=value] [-Ename=value] [-Tlang] [-l libfile] [-o outfile] [-v] [files]

DESCRIPTION
fdp draws undirected graphs using a ``spring'' model. It relies on a force-directed approach in the spirit of Fruchterman and Reingold (cf. Software-Practice & Experience 21(11), 1991, pp. 1129-1164). Input files must be formatted in the dot attributed graph language. By default, the output of fdp is the input graph with layout coordinates appended. To make Postscript, use the -Tps option. FrameMaker MIF (-Tmif), HPGL (-Thpgl), JPEG (-Tjpg and GIF (-Tgif) are other choices.

Here is a brief synopsis of the graph language.

graph name { statement-list }

declares a top level graph. Statements may be:

name=val;
node [name=val];
edge [name=val]; Set the default graph, node, or edge attribute name to val. Any subgraph, node, or edge specified after one of these statements inherits these attributes.

n0 [name0=val0,name1=val1,...]; Creates node n0 if it does not exist, and sets its attributes according to the optional list.

n0 -- n1 -- ... -- nn [name0=val0,name1=val1,...]; Creates edges between nodes n0, n1, ..., nn and optionally sets the given attributes. Creates nodes as necessary. Although typically applied to undirected graph, fdp will also layout directed graphs by simply ignoring edge direction.

subgraph name { statement-list } Creates a subgraph. A subgraph may appear in place of an individual node within an edge statement. The subgraph name part is optional. If missing, the subgraph is given an internal name.

While attribute names and values may be arbitrary strings, certain fixed attributes control fdp's layout algorithm. Refer to dot(1) for general options for controlling layout size, font faces and sizes, colors, labels, node shape, line styles, etc.

GRAPH ATTRIBUTES
K=val. Sets the default ideal node separation in the layout.

maxiter=val. Sets the maximum number of iterations used to layout the graph.

start=val. Adjusts the random initial placement of nodes with no specified position. If val is is an integer, it is used as the seed for the random number generator. If val is not an integer, a random system-generated integer, such as the process ID or current time, is used as the seed.

splines=val. If val is "true", edges are drawn as splines to avoid nodes. By default, edges are draw as line segments.

NODE ATTRIBUTES
pin=val. If val is "true", the node will remain at its initial position.

EDGE ATTRIBUTES
weight=f sets the weight of an edge to the given floating point value. The default is 1.0; greater values make the edge tend more toward its optimal length.

len=f sets the optimal length of an edge. The default is K.

COMMAND LINE OPTIONS
-v (verbose) prints a log of the layout.

-V prints the version and exits.

-? prints the usage and exits.

SEE ALSO
dot(1), circo(1), neato(1), twopi(1)