| addNodeData | R Documentation |
This function takes a node data frame, consisting of character
variables node and (optionally) group, and populates the nodes
list element in the supplied CLD object.
addNodeData(CLD, ndf, replace = FALSE, sorted = TRUE)
CLD |
A causal loop diagram (CLD) object. |
ndf |
A node data frame containing at least a character column |
replace |
If |
sorted |
If |
An updated CLD object.
## Not run:
L <- CLD(from=c("a","a","c","c","d"), to=c("b","c","a","d","a"))
L$nodes
ndat <- tibble(node=c("c","d","e","f"), group=c("I"," ","II","I"))
L <- addNodeData(L, ndat)
L$nodes #note updating behavior - also that the missing value gets mapped to "<default>"
M <- addNodeData(L, ndat, replace=TRUE) #produces error
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.