powered by
Modify the node labels of an existing sgraph object by providing an attribute from the initial igraph to use as the labels.
add_node_labels(sigma_obj, label_attr = NULL)
sgraph object with modified node labels
sgraph object, returned by sigma_from_igraph function
Attribute to use to replace node labels
library(igraph) library(sgraph) data(lesMis) sig <- sigma_from_igraph(igraph = lesMis) %>% add_node_labels(label_attr = 'label') sig
Run the code above in your browser using DataLab