org.apache.ignite.ml.tree

## Class DecisionTreeConditionalNode

- java.lang.Object
- - org.apache.ignite.ml.tree.DecisionTreeConditionalNode

- All Implemented Interfaces:
    Serializable, AutoCloseable, IgniteModel<Vector,Double>, Model<Vector,Double>, DecisionTreeNode

      public final class DecisionTreeConditionalNode
      extends Object
      implements DecisionTreeNode

  Decision tree conditional (non-leaf) node.
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DecisionTreeConditionalNode(int col, double threshold, DecisionTreeNode thenNode, DecisionTreeNode elseNode, DecisionTreeNode missingNode)` Constructs a new instance of decision tree conditional node.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `getCol()`
    `DecisionTreeNode` | `getElseNode()`
    `DecisionTreeNode` | `getMissingNode()`
    `DecisionTreeNode` | `getThenNode()`
    `double` | `getThreshold()`
    `Double` | `predict(Vector features)` Make a prediction for the specified input arguments.
    `void` | `setElseNode(DecisionTreeNode elseNode)`
    `void` | `setMissingNode(DecisionTreeNode missingNode)`
    `void` | `setThenNode(DecisionTreeNode thenNode)`
    `String` | `toString()`
    `String` | `toString(boolean pretty)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface org.apache.ignite.ml.IgniteModel

      `andBefore, andThen, andThen, close, combine`

- - ### Constructor Detail

    - #### DecisionTreeConditionalNode

          public DecisionTreeConditionalNode(int col,
                                             double threshold,
                                             DecisionTreeNode thenNode,
                                             DecisionTreeNode elseNode,
                                             DecisionTreeNode missingNode)

      Constructs a new instance of decision tree conditional node.
      Parameters:
        `col` - Column of the value to be tested.
        `threshold` - Threshold.
        `thenNode` - Node that will be used in case tested value is greater then threshold.
        `elseNode` - Node that will be used in case tested value is not greater then threshold.
        `missingNode` - Node that will be used in case tested value is not presented.

  - ### Method Detail

    - #### predict

          public Double predict(Vector features)

      Make a prediction for the specified input arguments.
      Specified by:
        `predict` in interface `Model<Vector,Double>`
      Parameters:
        `features` - Input arguments.
      Returns:
        Prediction result.

    - #### getCol

          public int getCol()

    - #### getThreshold

          public double getThreshold()

    - #### getThenNode

          public DecisionTreeNode getThenNode()

    - #### setThenNode

          public void setThenNode(DecisionTreeNode thenNode)

    - #### getElseNode

          public DecisionTreeNode getElseNode()

    - #### setElseNode

          public void setElseNode(DecisionTreeNode elseNode)

    - #### getMissingNode

          public DecisionTreeNode getMissingNode()

    - #### setMissingNode

          public void setMissingNode(DecisionTreeNode missingNode)

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### toString

          public String toString(boolean pretty)

      Specified by:
        `toString` in interface `IgniteModel<Vector,Double>`
      Parameters:
        `pretty` - Use pretty mode.

2020 Copyright © Apache Software Foundation
| Follow @ApacheIgnite
Ignite Database and Caching Platform | : ver. 2.9.1
Release Date | : December 9 2020