is_tree {simplextree}R Documentation

Checks if the simplicial complex is a tree.

Description

This function performs a breadth-first search on the simplicial complex, checking if the complex is acyclic.

Usage

is_tree(st)

Arguments

st

a simplex tree.

Examples

st <- simplex_tree()
st %>% insert(list(1:2, 2:3))
st %>% is_tree() # true
st %>% insert(c(1, 3))
st %>% is_tree() # false

[Package simplextree version 1.0.1 Index]