This is the final step in the MCML workflow, enabling full integration with
the tna package for centrality analysis, bootstrap validation, permutation
tests, and visualization.
Requirements
The tna package must be installed. If not available, the function throws
an error with installation instructions.
Workflow
# Full MCML workflow
net <- cograph(edges, nodes = nodes)
net$nodes$clusters <- group_assignments
cs <- csum(net, type = "tna")
tna_models <- as_tna(cs)
# Now use tna package functions
plot(tna_models$macro)
tna::centralities(tna_models$macro)
tna::bootstrap(tna_models$macro, iter = 1000)
# Analyze per-cluster patterns
plot(tna_models$ClusterA)
tna::centralities(tna_models$ClusterA)
Excluded Clusters
A per-cluster tna cannot be created when:
These clusters are left out of the result with a warning of class
cograph_cluster_dropped, which names each cluster and the nodes
that have no transition within it. The macro (cluster-level) model still
includes all clusters.