Learn R Programming

treeman (version 1.1.4)

setNdsOther: Set a user defined slot for multiple nodes

Description

Return a tree with a user defined slot for node IDs.

Usage

setNdsOther(tree, ids, vals, slt_nm, parallel = FALSE, progress = "none")

Arguments

tree

TreeMan object

ids

id sof the nodes

vals

data for slot

slt_nm

slot name

parallel

logical, make parallel?

progress

name of the progress bar to use, see create_progress_bar

Details

Runs setNdOther() over multiple nodes. Parellizable.

See Also

setNdOther https://github.com/DomBennett/treeman/wiki/set-methods

Examples

Run this code
# NOT RUN {
library(treeman)
tree <- randTree(10)
# e.g. confidences for nodes
vals <- runif(min=0, max=1, n=tree['nall'])
tree <- setNdsOther(tree, tree['all'], vals, 'confidence')
tree <- updateSlts(tree)
summary(tree)
(getNdsSlt(tree, ids=tree['all'], slt_nm='confidence'))
# }

Run the code above in your browser using DataLab