add_p: Add node or edge

Description Usage Arguments Value Note Examples

Description

Proxies to dynamically add a node or an edge to an already existing graph.

Usage

1
2
3
sg_add_node_p(proxy, data, ..., refresh = TRUE)

sg_add_edge_p(proxy, data, ..., refresh = TRUE)

Arguments

proxy

An object of class sigmajsProxy as returned by sigmajsProxy.

data

A data.frame of _one_ node or edge.

...

any column.

refresh

Whether to refresh the graph after node is dropped, required to take effect, if you are running force the algorithm is killed.

Value

The proxy object.

Note

Have the parameters from your initial graph match that of the node you add, i.e.: if you pass size in your initial chart, make sure you also have it in your proxy.

Examples

1
2
3
4
5
6
## Not run: 
demo("add-node", package = "sigmajs")
demo("add-edge", package = "sigmajs")
demo("add-node-edge", package = "sigmajs")

## End(Not run)

JohnCoene/sigmajs documentation built on Feb. 1, 2021, 12:12 p.m.