relayout_with_qfr: igraph re-layout using qgraph Fruchterman-Reingold

relayout_with_qfrR Documentation

igraph re-layout using qgraph Fruchterman-Reingold

Description

igraph re-layout using qgraph Fruchterman-Reingold

Usage

relayout_with_qfr(
  g,
  repulse = 3.5,
  spread_labels = TRUE,
  seed = 123,
  init = NULL,
  constrain = NULL,
  constraints = NULL,
  verbose = FALSE,
  ...
)

Arguments

g

igraph object

repulse

exponent power used to scale the radius effect around each vertex. The default is slightly higher than the cube of the number of vertices, but as the number of vertices increases, values from 3.5 to 4 and higher are more effective for layout.

spread_labels

logical indicating whether to call spread_igraph_labels(), which places node labels at an angle offset from the node, in order to improve default label positions.

...

additional arguments are passed to layout_with_qfr() and spread_igraph_labels() as needed.

Details

This function extends layout_with_qfr() by applying the layout to the igraph object itself, while also calling spread_igraph_labels() to adjust label positions accordingly.

The main benefit to using this function is to update the layout and node label positions in one step, while also returning the igraph object ready to be plotted as-is.

Value

igraph object, with layout coordinates stored in graph attribute "layout", accessible for example with graph$layout or graph_attr(graph, "layout"). When spread_labels=TRUE, V(g)$label.degree and V(g)$label.dist are updated by calling spread_igraph_labels().

See Also

Other jam igraph functions: cnet2df(), cnet2im(), cnetplotJam(), cnetplot_internalJam(), color_edges_by_nodegroups(), color_edges_by_nodes_deprecated(), color_edges_by_nodes(), color_nodes_by_nodegroups(), communities2nodegroups(), drawEllipse(), edge_bundle_bipartite(), edge_bundle_nodegroups(), enrichMapJam(), fixSetLabels(), flip_edges(), get_bipartite_nodeset(), igraph2pieGraph(), jam_igraph(), jam_plot_igraph(), label_communities(), layout_with_qfrf(), layout_with_qfr(), mem2emap(), memIM2cnet(), mem_multienrichplot(), nodegroups2communities(), rectifyPiegraph(), removeIgraphBlanks(), removeIgraphSinglets(), reorderIgraphNodes(), rotate_igraph_layout(), spread_igraph_labels(), subgraph_jam(), subsetCnetIgraph(), subset_igraph_components(), sync_igraph_communities(), with_qfr()


jmw86069/jamenrich documentation built on Nov. 6, 2024, 7:07 p.m.