Learn R Programming

MultivariateRandomForest (version 1.1)

predicting: Prediction of testing sample in a node

Description

Predicts a testing sample in a node, means which child node it will go using the splitting criteria of the model or, prediction results if the node is leaf.

Usage

predicting(Single_Model, i, X_test, Variable_number)

Arguments

Single_Model
Model of a particular tree
i
Number of split. Used as an index, which indicates where in the list the splitting criteria of this split has been stored.
X_test
Testing samples of Q x N, Q is the number of testing samples and N is the number of features(same order and size used as training)
Variable_number
Number of Output Features

Value

Prediction result of a Testing samples in a node

Details

In a particular node, a testing sample can go in two directions, left node and right node. If the value of splitting feature of the testing sample is less than thresohold splitting value, it will go to the left otherwise in the right node. While if the node is leaf, then average of output features are returned as the prediction results.