createNetworkFromIgraph | R Documentation |
Takes an igraph network and generates data frames for nodes and edges to send to the createNetwork function. Returns the network.suid and applies the perferred layout set in Cytoscape preferences.
createNetworkFromIgraph(
igraph,
title = "From igraph",
collection = "My Igraph Network Collection",
base.url = .defaultBaseUrl,
...
)
igraph |
(igraph) igraph network object |
title |
(char) network name |
collection |
(char) network collection name |
base.url |
(optional) Ignore unless you need to specify a custom domain, port or version to connect to the CyREST API. Default is http://localhost:1234 and the latest version of the CyREST API supported by this version of RCy3. |
... |
params for nodeSet2JSON() and edgeSet2JSON(); see createNetwork |
Vertices and edges from the igraph network will be translated into nodes and edges
in Cytoscape. Associated attributes will also be passed to Cytoscape as node and edge
table columns. Note: undirected networks will be implicitly modeled as directed
in Cytoscape. Conversion back via createIgraphFromNetwork
will result in
a directed network. Also note: igraph attributes of type "other" denoted by "x"
are converted to "String" in Cytoscape.
(int) network SUID
createNetworkFromDataFrames, createIgraphFromNetwork
library(igraph)
ig <- makeSimpleIgraph()
createNetworkFromIgraph(ig)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.