graph2lavaan | R Documentation |
Convert an igraph object to a model (lavaan syntax).
graph2lavaan(graph, nodes = V(graph)$name, ...)
graph |
A graph as an igraph object. |
nodes |
Subset of nodes to be included in the model. By default, all the input graph nodes will be included in the output model. |
... |
Currently ignored. |
A model in lavaan syntax.
Mario Grassi mario.grassi@unipv.it
# Graph (igraph object) to structural model in lavaan syntax
model <- graph2lavaan(sachs$graph)
cat(model, "\n")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.