Learn R Programming

sgraph (version 1.1.0)

Network Visualization Using 'sigma.js'

Description

Interactive visualizations of graphs created with the 'igraph' package using a 'htmlwidgets' wrapper for the 'sigma.js' network visualization v2.4.0 , enabling to display several thousands of nodes. While several 'R' packages have been developed to interface 'sigma.js', all were developed for v1.x.x and none have migrated to v2.4.0 nor are they planning to. This package builds upon the 'sigmaNet' package, and users familiar with it will recognize the similar design approach. Two extensions have been added to the classic 'sigma.js' visualizations by overriding the underlying 'JavaScript' code, enabling to draw a frame around node labels, and to display labels on multiple lines by parsing line breaks. Other additional functionalities that did not require overriding 'sigma.js' code include toggling node visibility when clicked using a node attribute and highlighting specific edges. 'sigma.js' is currently preparing a stable release v3.0.0, and this package plans to update to it when it is available.

Copy Link

Version

Install

install.packages('sgraph')

Monthly Downloads

206

Version

1.1.0

License

GPL-3

Maintainer

Thomas Charlon

Last Published

August 19th, 2024

Functions in sgraph (1.1.0)

add_edge_zindex

Modify the edge zIndex of a sgraph object.
add_node_labels

Modify the node labels of a sgraph object.
%<>%

Assignment pipe
convert_to_spring_weights

Convert weights for spring layout
add_igraph_info

Add nodes information to the igraph object
add_node_size

Modify the node size of a sgraph object.
add_listener

Add a listener
%>%

Pipe
get_color_map

Build a color map
kgraph_to_lgraph

Kgraph fit to graph list object
l_graph_to_igraph

Graph list object to igraph object
add_edge_size

Modify the edge size of a sgraph object.
add_node_hidden

Modify the node visibility of a sgraph object.
highlight_multiple_connected

Highlight edges of multiple connected nodes
renderSgraph

Render a sgraph visualization in Shiny
get_legend

Get the legend for a sgraph network
lesMis

Co-appearances of characters in "Les Miserables"
sgraph_clusters

Build a sgraph object colored by clusters
%$%

Exposition pipe
sigma_from_igraph

Build a sgraph object from an igraph object
multiline_labels

Format multiline labels
scale_graph

Scale weights
sgraphOutput

Create a UI element for a sgraph visualization in Shiny
add_edge_color

Modify the edge colors of a sgraph object.