Skip to contents

Format a subtree, produced by extract_subtree(), as a text-based tree mirroring disease-ontology.org.

Usage

format_subtree(subtree_df, top_node)

Arguments

subtree_df

A dataframe from extract_subtree().

top_node

The top node of the tree, as a valid DOID (see is_valid_doid() for valid input formats).

Examples

if (FALSE) {
    do_owl <- {path_to_doid.owl_here}
    subtree <- extract_subtree(do_owl, "DOID:3070")
    st_formatted <- format_subtree(subtree, "DOID:3070")
    st_formatted
}