is_combined: Given a graph and a node, determine if the node is a result...

View source: R/UpdateKlass-graph-navigate.R

is_combinedR Documentation

Given a graph and a node, determine if the node is a result of combinations of multiple codes.

Description

Given a graph and a node, determine if the node is a result of combinations of multiple codes.

Usage

is_combined(graph, node, compare_node = NULL)

Arguments

graph

A graph generated by klass_graph.

node

A node as returned by klass_node or V.

compare_node

Optional. A node to compare node with when determining whether node is combined. See details.

Details

The function will attempt to reconcile nodes that have split and then later merged again when evaluating a node's combinedness.

If compare_node == NULL, a node is considered to be combined if more than one node that does not itself have a parent (i.e. codes at the start of a sequence of changes) contribute to node.

If compare_node != NULL, a node is considered to be combined if any node that is not an ancestor of compare_node contributes to node, i.e. all paths from node to the parents of node pass through compare_node.

Value

TRUE if the node is a combination of two or more nodes, otherwise FALSE.


klassR documentation built on April 4, 2025, 4:16 a.m.

Related to is_combined in klassR...