Uses the gexf-js JavaScript viewer by copying static files to a directory
and optionally launching a local web server via the servr package. For
the modern htmlwidget-based renderer, use plot.gexf or sigmajs.
gexf_js_config(
dir,
graphFile = "network.gexf",
showEdges = TRUE,
useLens = FALSE,
zoomLevel = 0,
curvedEdges = TRUE,
edgeWidthFactor = 1,
minEdgeWidth = 1,
maxEdgeWidth = 50,
textDisplayThreshold = 9,
nodeSizeFactor = 1,
replaceUrls = TRUE,
showEdgeWeight = TRUE,
showEdgeLabel = TRUE,
sortNodeAttributes = TRUE,
showId = TRUE,
showEdgeArrow = TRUE,
language = FALSE
)plot_gexfjs(
x,
graphFile = "network.gexf",
dir = tempdir(),
overwrite = TRUE,
httd.args = list(),
copy.only = FALSE,
...
)
Directory where files are copied (tempdir() by default).
Name of the GEXF file written to dir.
Logical scalar. Default state of the "show edges" button (nullable).
Logical scalar. Default state of the "use lens" button (nullable).
Numeric scalar. Default zoom level. At zoom = 0, the graph should fill a 800x700px zone
Logical scalar. False for curved edges, true for straight edges this setting can't be changed from the User Interface.
Numeric scalar. Change this parameter for wider or narrower edges this setting can't be changed from the User Interface.
Numeric scalar.
Numeric scalar.
Numeric scalar.
Numeric scalar. Change this parameter for smaller or larger nodes this setting can't be changed from the User Interface.
Logical scalar. Enable the replacement of Urls by Hyperlinks this setting can't be changed from the User Interface.
Logical scalar. Show the weight of edges in the list this setting can't be changed from the User Interface.
Logical scalar.
Logical scalar. Alphabetically sort node attributes.
Logical scalar. Show the id of the node in the list this setting can't be changed from the User Interface.
Logical scalar. Show the edge arrows when the edge is directed this setting can't be changed from the User Interface.
Either FALSE, or a character scalar with any of the
supported languages.
An object of class gexf.
Logical scalar. Overwrite existing files in dir.
Further arguments passed to servr::httd.
Logical. When TRUE, skip launching the server.
Further arguments passed to gexf_js_config.
Currently, the only languages supported are: German (de), English (en), French (fr), Spanish (es), Italian (it), Finnish (fi), Turkish (tr), Greek (el), Dutch (nl)
The server is launched only when interactive() == TRUE and
copy.only == FALSE.
gexf-js project website https://github.com/raphv/gexf-js.
if (interactive()) {
path <- system.file("gexf-graphs/lesmiserables.gexf", package = "rgexf")
graph <- read.gexf(path)
plot_gexfjs(graph)
}
Run the code above in your browser using DataLab