Class RegTree

java.lang.Object
biz.k11i.xgboost.tree.RegTree
All Implemented Interfaces:
Serializable

public class RegTree extends Object implements Serializable
Regression tree.
See Also:
  • Field Details

  • Constructor Details

    • RegTree

      public RegTree()
  • Method Details

    • loadModel

      public void loadModel(ModelReader reader) throws IOException
      Loads model from stream.
      Parameters:
      reader - input stream
      Throws:
      IOException - If an I/O error occurs
    • getLeafIndex

      public int getLeafIndex(FVec feat, int root_id)
      Retrieves nodes from root to leaf and returns leaf index.
      Parameters:
      feat - feature vector
      root_id - starting root index
      Returns:
      leaf index
    • getLeafValue

      public float getLeafValue(FVec feat, int root_id)
      Retrieves nodes from root to leaf and returns leaf value.
      Parameters:
      feat - feature vector
      root_id - starting root index
      Returns:
      leaf value