function that calculate the probability of being at the node
node_prob(node, tree)
| node | the number of the node in the tree |
|---|---|
| tree | a tree. A data frame returned by the function |
a numeric indicating the probability that an observation falls into a node.