Class: Rumale::Tree::ExtraTreeRegressor
- Inherits:
-
DecisionTreeRegressor
- Object
- Base::Estimator
- BaseDecisionTree
- DecisionTreeRegressor
- Rumale::Tree::ExtraTreeRegressor
- Defined in:
- rumale-tree/lib/rumale/tree/extra_tree_regressor.rb
Overview
ExtraTreeRegressor is a class that implements extra randomized tree for regression.
Reference
-
Geurts, P., Ernst, D., and Wehenkel, L., “Extremely randomized trees,” Machine Learning, vol. 63 (1), pp. 3–42, 2006.
Instance Attribute Summary collapse
-
#feature_importances ⇒ Numo::DFloat
readonly
Return the importance for each feature.
-
#leaf_values ⇒ Numo::DFloat
readonly
Return the values assigned each leaf.
-
#rng ⇒ Random
readonly
Return the random generator for random selection of feature index.
-
#tree ⇒ Node
readonly
Return the learned tree.
Attributes inherited from Base::Estimator
Instance Method Summary collapse
-
#initialize(criterion: 'mse', max_depth: nil, max_leaf_nodes: nil, min_samples_leaf: 1, max_features: nil, random_seed: nil) ⇒ ExtraTreeRegressor
constructor
Create a new regressor with extra randomized tree algorithm.
Methods inherited from DecisionTreeRegressor
Methods included from Base::Regressor
Methods inherited from BaseDecisionTree
Constructor Details
#initialize(criterion: 'mse', max_depth: nil, max_leaf_nodes: nil, min_samples_leaf: 1, max_features: nil, random_seed: nil) ⇒ ExtraTreeRegressor
Create a new regressor with extra randomized tree algorithm.
49 50 51 52 |
# File 'rumale-tree/lib/rumale/tree/extra_tree_regressor.rb', line 49 def initialize(criterion: 'mse', max_depth: nil, max_leaf_nodes: nil, min_samples_leaf: 1, max_features: nil, random_seed: nil) super end |
Instance Attribute Details
#feature_importances ⇒ Numo::DFloat (readonly)
Return the importance for each feature.
23 24 25 |
# File 'rumale-tree/lib/rumale/tree/extra_tree_regressor.rb', line 23 def feature_importances @feature_importances end |
#leaf_values ⇒ Numo::DFloat (readonly)
Return the values assigned each leaf.
35 36 37 |
# File 'rumale-tree/lib/rumale/tree/extra_tree_regressor.rb', line 35 def leaf_values @leaf_values end |
#rng ⇒ Random (readonly)
Return the random generator for random selection of feature index.
31 32 33 |
# File 'rumale-tree/lib/rumale/tree/extra_tree_regressor.rb', line 31 def rng @rng end |
#tree ⇒ Node (readonly)
Return the learned tree.
27 28 29 |
# File 'rumale-tree/lib/rumale/tree/extra_tree_regressor.rb', line 27 def tree @tree end |