formatToHierarchicalData: Format data to a hierarchical data, in the format as required...

Description Usage Arguments Value Author(s)

View source: R/plots-utility-formatToHierarchicalData.R

Description

Note that new variables are created for each variable of interest (the variables are not overwritten) to avoid issues with cases where the value in the child and parent variables are the same.

Usage

1
formatToHierarchicalData(data, vars, valueVar)

Arguments

data

Data.frame with data.

vars

Character vector with variables of data containing plot nodes. If multiple, they should be specified in hierarchical order (from parent to child node).

valueVar

String with numeric variable of data containing node value, and associated label.

Value

Updated data.frame with vars in hierarchical format, with extra attributes (in 'metadat'):

Author(s)

Laure Cougnaud


clinDataReview documentation built on July 14, 2021, 5:08 p.m.