The subtree function returns a tree from a selected node of the semtree returned tree.

subtree(tree, startNode = NULL, level = 0, foundNode = FALSE)

Arguments

tree

A SEMtree object obtained from semtree

startNode

Node id, which will be future root node (0 to max node number of tree)

level

Ignore. Only used internally.

foundNode

Ignore. Only used internally.

Value

Returns a semtree object which is a partitioned tree from the input semtree.

Details

The row names of the resulting data frame correspond to internal node ids and the column names correspond to standard errors in the SEM. Standard errors of the estimates can be obtained from se.

References

Brandmaier, A.M., Oertzen, T. v., McArdle, J.J., & Lindenberger, U. (2013). Structural equation model trees. Psychological Methods, 18(1), 71-86.

Author

Andreas M. Brandmaier, John J. Prindle