Description Usage Arguments Details Examples
Make a dtree from one of two constructors:
A vector of node Ids and parent node Ids or
A vector of node Ids, left-child Ids, and right-child Ids
1 2  | make_dtree(nodeIds, leftChildIds, rightChildIds, splitVars = NULL,
  splitVals = NULL, data = NULL)
 | 
nodeIds | 
 A vector of node Ids  | 
leftChildIds | 
 A vector of left-child node Ids  | 
rightChildIds | 
 A vector of right-child node Ids  | 
parentNodeIds | 
 A vector of parent node Ids  | 
Returns a dtree object
1 2 3 4 5  | library(data.table)
make_dtree(nodeIds=c(1), leftChildIds=c(NA_integer_), rightChildIds=c(NA_integer_))
make_dtree(nodeIds=c(1), leftChildIds=c(2), rightChildIds=c(3), splitVars=c("foo"), splitVals=c(3.5))
make_dtree(nodeIds=c(1,2,3), leftChildIds=c(2,NA,NA), rightChildIds=c(3,NA,NA), splitVars=c("foo",NA,NA), splitVals=c(3.5,NA,NA))
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.