This function plots a transition network analysis (TNA) model using
the qgraph package. The nodes in the graph represent states, with node
sizes corresponding to initial state probabilities. Edge labels represent
the edge weights of the network.
# S3 method for tna
plot(
x,
node_list,
use_list_order = TRUE,
x_offset,
labels,
colors,
pie,
cut,
show_pruned = TRUE,
pruned_edge_color = "pink",
edge.color = NA,
edge.labels = TRUE,
edge.label.position = 0.65,
layout = "circle",
layout_args = list(),
scale_nodes,
scaling_factor = 0.5,
mar = rep(5, 4),
theme = "colorblind",
...
)A qgraph plot of the transition network.
A tna object from tna().
An optional list of two character vectors that define
two mutually exclusive groups of node labels.
A logical value. If node_list is provided,
defines how the order of the nodes in the plot is defined. A TRUE value
uses the order in node_list. Otherwise, the nodes are ranked based on
edge weights and ordered according to the rank.
An optional numeric vector with the same number of
elements as there are states. Defines a horizontal offset for each node
in the plot when node_list is provided.
See qgraph::qgraph().
See qgraph::qgraph().
See qgraph::qgraph().
Edge color and width emphasis cutoff value. The default is
the median of the edge weights. See qgraph::qgraph() for details.
A logical value indicating if pruned edges removed by
prune() should be shown in the plot. The default is TRUE, and the
edges are drawn as dashed with a different color to distinguish them.
A character string for the color to use for
pruned edges when show_pruned = TRUE. The default is "pink".
See qgraph::qgraph().
See qgraph::qgraph().
See qgraph::qgraph().
One of the following:
A character string describing a qgraph layout (e.g., "circle")
or the name of a igraph layout function (e.g., "layout_on_grid").
A matrix of node positions to use, with a row for each node and
x and y columns for the node positions.
A layout function from igraph.
A list of arguments to pass to the igraph layout
function when layout is a function or a character string that specifies
a function name.
A character string giving the name of a centrality
measure to scale the node size by. See centralities() for valid names.
If missing (the default), uses default qgraph::qgraph() scaling.
The value of vsize provided via ... is used as baseline size.
A numeric value specifying how strongly to scale
the nodes when scale_nodes is provided. Values
between 0 and 1 will result in smaller differences and values larger
than 1 will result in greater differences. The default is 0.5.
See qgraph::qgraph().
See qgraph::qgraph().
Additional arguments passed to qgraph::qgraph().
Basic functions
build_model(),
hist.group_tna(),
hist.tna(),
plot.group_tna(),
plot_frequencies(),
plot_frequencies.group_tna(),
plot_mosaic(),
plot_mosaic.group_tna(),
plot_mosaic.tna_data(),
print.group_tna(),
print.summary.group_tna(),
print.summary.tna(),
print.tna(),
summary.group_tna(),
summary.tna(),
tna-package
model <- tna(group_regulation)
plot(model)
Run the code above in your browser using DataLab