class DecisionTreeModel extends Serializable with Saveable
Decision tree model for classification or regression. This model stores the decision tree structure and parameters.
- Annotations
- @Since( "1.0.0" )
- Alphabetic
- By Inheritance
- DecisionTreeModel
- Saveable
- Serializable
- Serializable
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
val
algo: Algo
- Annotations
- @Since( "1.0.0" )
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
depth: Int
Get depth of tree.
Get depth of tree. E.g.: Depth 0 means 1 leaf node. Depth 1 means 1 internal node and 2 leaf nodes.
- Annotations
- @Since( "1.1.0" )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
formatVersion: String
Current version of model save/load format.
Current version of model save/load format.
- Attributes
- protected
- Definition Classes
- DecisionTreeModel → Saveable
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
numNodes: Int
Get number of nodes in tree, including leaf nodes.
Get number of nodes in tree, including leaf nodes.
- Annotations
- @Since( "1.1.0" )
-
def
predict(features: JavaRDD[Vector]): JavaRDD[Double]
Predict values for the given data set using the model trained.
Predict values for the given data set using the model trained.
- features
JavaRDD representing data points to be predicted
- returns
JavaRDD of predictions for each of the given data points
- Annotations
- @Since( "1.2.0" )
-
def
predict(features: RDD[Vector]): RDD[Double]
Predict values for the given data set using the model trained.
Predict values for the given data set using the model trained.
- features
RDD representing data points to be predicted
- returns
RDD of predictions for each of the given data points
- Annotations
- @Since( "1.0.0" )
-
def
predict(features: Vector): Double
Predict values for a single data point using the model trained.
Predict values for a single data point using the model trained.
- features
array representing a single data point
- returns
Double prediction from the trained model
- Annotations
- @Since( "1.0.0" )
-
def
save(sc: SparkContext, path: String): Unit
- sc
Spark context used to save model data.
- path
Path specifying the directory in which to save this model. If the directory already exists, this method throws an exception.
- Definition Classes
- DecisionTreeModel → Saveable
- Annotations
- @Since( "1.3.0" )
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toDebugString: String
Print the full model to a string.
Print the full model to a string.
- Annotations
- @Since( "1.2.0" )
-
def
toString(): String
Print a summary of the model.
Print a summary of the model.
- Definition Classes
- DecisionTreeModel → AnyRef → Any
-
val
topNode: Node
- Annotations
- @Since( "1.0.0" )
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )