plot.network
visualization routine.
network.layout.circle(nw, layout.par)
network.layout.fruchtermanreingold(nw, layout.par)
network.layout.kamadakawai(nw, layout.par)
plot.network
. d
.
plot.network
allows for the use of arbitrary vertex layout algorithms via the network.layout.*
family of routines. When called, plot.network
searches for a network.layout
function whose fourth name matches its mode
argument (see plot.network
help for more information); this function is then used to generate the layout for the resulting plot. In addition to the routines documented here, users may add their own layout functions as needed. The requirements for a network.layout
function are as follows:
nw
, must be a network object;
layout.par
, must be a list of parameters (or NULL
, if no parameters are specified); and
c(2,network.size(nw))
, whose rows contain the vertex coordinates.
Other than this, anything goes. (In particular, note that layout.par
could be used to pass additional matrices or other information, if needed. Alternately, it is possible to make layout methods that respond to covariates on the network object, which are maintained intact by plot.network.)
The network.layout
functions currently supplied by default are as follows (with n==network.size(nw)
):
n
.)
n^2
.)
area*log(n)
.)
ncell
by ncell
cells, which are used to define neighborhoods for force calculation. Moderate numbers of cells result in fastest performance; too few cells (down to 1, which produces pure F-R results) can yield odd layouts, while too many will result in long layout times. (Defaults to n^0.4
.)
0.5
.)
0
.)
18
.)
ncell^2
.)
n/4
.)
n)^2
.)
nw
after symmetrizing, capped at sqrt(n)
.)
Fruchterman, T.M.J. and Reingold, E.M. (1991). Graph Drawing by Force-directed Placement. Software - Practice and Experience, 21(11):1129-1164.
Kamada, T. and Kawai, S. (1989). An Algorithm for Drawing General Undirected Graphs. Information Processing Letters, 31(1):7-15.
plot.network