add_root_row: Add a row to the edges list to represent the root node (if...

View source: R/MullerPlot.R

add_root_rowR Documentation

Add a row to the edges list to represent the root node (if not already present).

Description

Add a row to the edges list to represent the root node (if not already present).

Usage

add_root_row(tree)

Arguments

tree

Dataframe comprising an adjacency matrix, with column names "Parent" and "Identity"

Value

The same dataframe including a row representing the root node.

Author(s)

Rob Noble, robjohnnoble@gmail.com

Examples

tree1 <- data.frame(Parent = c(1,1,1,2,3,4), 
                    Identity = 2:7)
add_root_row(tree1)


robjohnnoble/ggmuller documentation built on Sept. 18, 2023, 2:09 p.m.