Description Usage Arguments Value See Also Examples
Places node coordinates in the two-dimensional Euclidean plane.
1 2 |
graph |
[ |
n |
[ |
generator |
[ |
coordinates |
[ |
by.centers |
[ |
skip.centers |
[ |
par.fun |
[ |
... |
[any] |
[grapherator
] Graph.
Other graph generators: addEdges
,
addWeights
, graph
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | # Clustered graph
g = graph(0, 1000)
g = addNodes(g, n = 5, generator = addNodesLHS)
g = addNodes(g, n = c(3, 10, 20, 10, 40), by.centers = TRUE, generator = addNodesUniform,
lower = c(0, 0), upper = c(30, 30))
## Not run:
plot(g, show.edges = FALSE)$pl.coords
## End(Not run)
# Mixed graph
g = graph(0, 100)
g = addNodes(g, n = 100, generator = addNodesLHS)
g = addNodes(g, n = 100, generator = addNodesGrid)
## Not run:
plot(g, show.edges = FALSE)$pl.coords
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.