回帰用のバイナリ決定木をあてはめる
は、table tree
= fitrtree(Tbl
,ResponseVarName
)Tbl
内の入力変数 (予測子、特徴量、属性とも呼ばれます) と Tbl.ResponseVarName
に格納されている出力 (応答) に基づいて、回帰木を返します。返される tree
は、Tbl
の列の値に基づいて各枝ノードが分割される二分木です。
では、前の構文におけるいずれかの入力引数の組み合わせに加えて、1 つ以上の名前と値のペアの引数を使用してオプションを指定します。たとえば、観測値の重みを指定したり、交差検証済みモデルを学習させることができます。tree
= fitrtree(___,Name,Value
)
標本データを読み込みます。
load carsmall
標本データを使用して回帰木を構築します。応答変数は、ガロンあたりの走行マイル数 (MPG) です。
tree = fitrtree([Weight, Cylinders],MPG,... 'CategoricalPredictors',2,'MinParentSize',20,... 'PredictorNames',{'W','C'})
tree = RegressionTree PredictorNames: {'W' 'C'} ResponseName: 'Y' CategoricalPredictors: 2 ResponseTransform: 'none' NumObservations: 94 Properties, Methods
気筒数が 4、6 および 8 で、重さが約 1.8t (4,000 ポンド) の車の燃費を予測します。
MPG4Kpred = predict(tree,[4000 4; 4000 6; 4000 8])
MPG4Kpred = 3×1
19.2778
19.2778
14.3889
既定では、fitrtree
は深い決定木を成長させます。モデルの複雑さや計算時間の削減のために、より浅い木を成長させることもできます。木の深さを制御するには、名前と値のペアの引数 'MaxNumSplits'
、'MinLeafSize'
または 'MinParentSize'
を使用します。
carsmall
データセットを読み込みます。Displacement
、Horsepower
および Weight
が応答 MPG
の予測子であると考えます。
load carsmall
X = [Displacement Horsepower Weight];
回帰木を成長させる場合、木の深さの制御に関する既定値は次のとおりです。
MaxNumSplits
は n - 1
。n
は学習標本のサイズです。
MinLeafSize
は 1
。
MinParentSize
は 10
。
これらの既定値を使用すると、学習標本のサイズが大きい場合に木が深く成長する傾向があります。
木の深さの制御について既定値を使用して、回帰木を学習させます。10 分割の交差検証をモデルに対して実行します。
rng(1); % For reproducibility MdlDefault = fitrtree(X,MPG,'CrossVal','on');
木に適用される分割数のヒストグラムを描画します。適用される分割数は、葉の数より 1 つ小さい値です。また、木の 1 つを表示します。
numBranches = @(x)sum(x.IsBranch); mdlDefaultNumSplits = cellfun(numBranches, MdlDefault.Trained); figure; histogram(mdlDefaultNumSplits)
view(MdlDefault.Trained{1},'Mode','graph')
分割数の平均は 14 ~ 15 です。
既定の分割数を使用して学習させたものほど複雑ではない (深くない) 回帰木が必要であるとします。最大分割数を 7 に設定して別の回帰木を学習させます。これにより、既定値を使用した回帰木の平均分割数の約半分になります。10 分割の交差検証をモデルに対して実行します。
Mdl7 = fitrtree(X,MPG,'MaxNumSplits',7,'CrossVal','on'); view(Mdl7.Trained{1},'Mode','graph')
モデルの交差検証平均二乗誤差 (MSE) を比較します。
mseDefault = kfoldLoss(MdlDefault)
mseDefault = 25.7383
mse7 = kfoldLoss(Mdl7)
mse7 = 26.5748
Mdl7
は、MdlDefault
より大幅に単純化されており、性能は少しだけ低下します。
fitrtree
を使用してハイパーパラメーターを自動的に最適化します。
carsmall
データセットを読み込みます。
load carsmall
Weight
と Horsepower
を MPG
の予測子として使用します。自動的なハイパーパラメーター最適化を使用して、5 分割交差検証損失を最小化するハイパーパラメーターを求めます。
再現性を得るために、乱数シードを設定し、'expected-improvement-plus'
の獲得関数を使用します。
X = [Weight,Horsepower]; Y = MPG; rng default Mdl = fitrtree(X,Y,'OptimizeHyperparameters','auto',... 'HyperparameterOptimizationOptions',struct('AcquisitionFunctionName',... 'expected-improvement-plus'))
|======================================================================================| | Iter | Eval | Objective: | Objective | BestSoFar | BestSoFar | MinLeafSize | | | result | log(1+loss) | runtime | (observed) | (estim.) | | |======================================================================================| | 1 | Best | 3.2818 | 0.39427 | 3.2818 | 3.2818 | 28 |
| 2 | Accept | 3.4183 | 0.084009 | 3.2818 | 3.2888 | 1 |
| 3 | Best | 3.1457 | 0.09611 | 3.1457 | 3.1628 | 4 |
| 4 | Best | 2.9885 | 0.08938 | 2.9885 | 2.9885 | 9 |
| 5 | Accept | 2.9978 | 0.11624 | 2.9885 | 2.9885 | 7 |
| 6 | Accept | 3.0203 | 0.096423 | 2.9885 | 3.0013 | 8 |
| 7 | Accept | 2.9885 | 0.09303 | 2.9885 | 2.9981 | 9 |
| 8 | Best | 2.9589 | 0.19407 | 2.9589 | 2.9589 | 10 |
| 9 | Accept | 3.078 | 0.074451 | 2.9589 | 2.9888 | 13 |
| 10 | Accept | 4.1881 | 0.10197 | 2.9589 | 2.9592 | 50 |
| 11 | Accept | 3.4182 | 0.077938 | 2.9589 | 2.9592 | 2 |
| 12 | Accept | 3.0376 | 0.06513 | 2.9589 | 2.9591 | 6 |
| 13 | Accept | 3.1453 | 0.11202 | 2.9589 | 2.9591 | 20 |
| 14 | Accept | 2.9589 | 0.067968 | 2.9589 | 2.959 | 10 |
| 15 | Accept | 3.0123 | 0.067048 | 2.9589 | 2.9728 | 11 |
| 16 | Accept | 2.9589 | 0.081551 | 2.9589 | 2.9593 | 10 |
| 17 | Accept | 3.3055 | 0.096765 | 2.9589 | 2.9593 | 3 |
| 18 | Accept | 2.9589 | 0.10245 | 2.9589 | 2.9592 | 10 |
| 19 | Accept | 3.4577 | 0.091951 | 2.9589 | 2.9591 | 37 |
| 20 | Accept | 3.2166 | 0.079191 | 2.9589 | 2.959 | 16 |
|======================================================================================| | Iter | Eval | Objective: | Objective | BestSoFar | BestSoFar | MinLeafSize | | | result | log(1+loss) | runtime | (observed) | (estim.) | | |======================================================================================| | 21 | Accept | 3.107 | 0.075289 | 2.9589 | 2.9591 | 5 |
| 22 | Accept | 3.2818 | 0.14343 | 2.9589 | 2.959 | 24 |
| 23 | Accept | 3.3226 | 0.094603 | 2.9589 | 2.959 | 32 |
| 24 | Accept | 4.1881 | 0.10136 | 2.9589 | 2.9589 | 43 |
| 25 | Accept | 3.1789 | 0.1151 | 2.9589 | 2.9589 | 18 |
| 26 | Accept | 3.0992 | 0.16808 | 2.9589 | 2.9589 | 14 |
| 27 | Accept | 3.0556 | 0.09539 | 2.9589 | 2.9589 | 22 |
| 28 | Accept | 3.0459 | 0.077797 | 2.9589 | 2.9589 | 12 |
| 29 | Accept | 3.2818 | 0.069777 | 2.9589 | 2.9589 | 26 |
| 30 | Accept | 3.4361 | 0.068911 | 2.9589 | 2.9589 | 34 |
__________________________________________________________ Optimization completed. MaxObjectiveEvaluations of 30 reached. Total function evaluations: 30 Total elapsed time: 54.2938 seconds Total objective function evaluation time: 3.1917 Best observed feasible point: MinLeafSize ___________ 10 Observed objective function value = 2.9589 Estimated objective function value = 2.9589 Function evaluation time = 0.19407 Best estimated feasible point (according to models): MinLeafSize ___________ 10 Estimated objective function value = 2.9589 Estimated function evaluation time = 0.097561
Mdl = RegressionTree ResponseName: 'Y' CategoricalPredictors: [] ResponseTransform: 'none' NumObservations: 94 HyperparameterOptimizationResults: [1x1 BayesianOptimization] Properties, Methods
carsmall
データセットを読み込みます。与えられた加速、気筒数、エンジン排気量、馬力、製造業者、モデル年および重量に対して自動車の燃費の平均を予測するモデルを考えます。Cylinders
、Mfg
および Model_Year
はカテゴリカル変数であるとします。
load carsmall Cylinders = categorical(Cylinders); Mfg = categorical(cellstr(Mfg)); Model_Year = categorical(Model_Year); X = table(Acceleration,Cylinders,Displacement,Horsepower,Mfg,... Model_Year,Weight,MPG);
カテゴリカル変数で表現されるカテゴリの個数を表示します。
numCylinders = numel(categories(Cylinders))
numCylinders = 3
numMfg = numel(categories(Mfg))
numMfg = 28
numModelYear = numel(categories(Model_Year))
numModelYear = 3
Cylinders
と Model_Year
には 3 つしかカテゴリがないので、予測子分割アルゴリズムの標準 CART ではこの 2 つの変数よりも連続予測子が分割されます。
データセット全体を使用して回帰木に学習をさせます。偏りの無い木を成長させるため、予測子の分割に曲率検定を使用するよう指定します。データには欠損値が含まれているので、代理分岐を使用するよう指定します。
Mdl = fitrtree(X,'MPG','PredictorSelection','curvature','Surrogate','on');
すべての予測子について分割によるリスク変動を合計し、この合計を枝ノード数で除算することにより、予測子の重要度の値を推定します。棒グラフを使用して推定を比較します。
imp = predictorImportance(Mdl); figure; bar(imp); title('Predictor Importance Estimates'); ylabel('Estimates'); xlabel('Predictors'); h = gca; h.XTickLabel = Mdl.PredictorNames; h.XTickLabelRotation = 45; h.TickLabelInterpreter = 'none';
このケースでは、最も重要な予測子は Displacement
であり、次に重要なのは Horsepower
です。
既定では、fitrtree
は深い決定木を成長させます。tall 配列の通過回数が少なくなる、より浅い木を構築します。名前と値のペアの引数 'MaxDepth'
を使用して、最大の木の深さを制御します。
tall 配列に対する計算を実行する場合、MATLAB® は並列プール (Parallel Computing Toolbox™ がある場合は既定) またはローカルの MATLAB セッションを使用します。Parallel Computing Toolbox がある場合でもローカルの MATLAB セッションを使用して例を実行するには、関数mapreducer
を使用してグローバルな実行環境を変更できます。
carsmall
データセットを読み込みます。Displacement
、Horsepower
および Weight
が応答 MPG
の予測子であると考えます。
load carsmall
X = [Displacement Horsepower Weight];
インメモリ配列 X
および MPG
を tall 配列に変換します。
tx = tall(X);
Starting parallel pool (parpool) using the 'local' profile ... Connected to the parallel pool (number of workers: 6).
ty = tall(MPG);
すべての観測値を使用して回帰木を成長させます。可能な最大の深さまで木が成長することを許可します。
再現性を得るため、rng
と tallrng
を使用して乱数発生器のシードを設定します。tall 配列の場合、ワーカーの個数と実行環境によって結果が異なる可能性があります。詳細については、コードの実行場所の制御を参照してください。
rng('default') tallrng('default') Mdl = fitrtree(tx,ty);
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 2: Completed in 3.3 sec - Pass 2 of 2: Completed in 1 sec Evaluation completed in 6.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 6: Completed in 1.4 sec - Pass 2 of 6: Completed in 0.41 sec - Pass 3 of 6: Completed in 2.3 sec - Pass 4 of 6: Completed in 3.6 sec - Pass 5 of 6: Completed in 1.5 sec - Pass 6 of 6: Completed in 2.9 sec Evaluation completed in 14 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.45 sec - Pass 2 of 7: Completed in 0.36 sec - Pass 3 of 7: Completed in 1.2 sec - Pass 4 of 7: Completed in 2.5 sec - Pass 5 of 7: Completed in 0.85 sec - Pass 6 of 7: Completed in 1.4 sec - Pass 7 of 7: Completed in 2.2 sec Evaluation completed in 10 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.45 sec - Pass 2 of 7: Completed in 0.36 sec - Pass 3 of 7: Completed in 1.1 sec - Pass 4 of 7: Completed in 2.6 sec - Pass 5 of 7: Completed in 1 sec - Pass 6 of 7: Completed in 1.5 sec - Pass 7 of 7: Completed in 3.2 sec Evaluation completed in 12 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.43 sec - Pass 2 of 7: Completed in 0.38 sec - Pass 3 of 7: Completed in 1.6 sec - Pass 4 of 7: Completed in 2.6 sec - Pass 5 of 7: Completed in 0.89 sec - Pass 6 of 7: Completed in 1.2 sec - Pass 7 of 7: Completed in 2.3 sec Evaluation completed in 11 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.47 sec - Pass 2 of 7: Completed in 0.38 sec - Pass 3 of 7: Completed in 1.1 sec - Pass 4 of 7: Completed in 2 sec - Pass 5 of 7: Completed in 0.76 sec - Pass 6 of 7: Completed in 1.2 sec - Pass 7 of 7: Completed in 2.4 sec Evaluation completed in 9.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.42 sec - Pass 2 of 7: Completed in 0.33 sec - Pass 3 of 7: Completed in 1.2 sec - Pass 4 of 7: Completed in 2.2 sec - Pass 5 of 7: Completed in 0.82 sec - Pass 6 of 7: Completed in 1.3 sec - Pass 7 of 7: Completed in 2.2 sec Evaluation completed in 9.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.49 sec - Pass 2 of 7: Completed in 0.36 sec - Pass 3 of 7: Completed in 1.1 sec - Pass 4 of 7: Completed in 2.8 sec - Pass 5 of 7: Completed in 1.2 sec - Pass 6 of 7: Completed in 1.1 sec - Pass 7 of 7: Completed in 2.3 sec Evaluation completed in 10 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.5 sec - Pass 2 of 7: Completed in 0.34 sec - Pass 3 of 7: Completed in 1.1 sec - Pass 4 of 7: Completed in 1.8 sec - Pass 5 of 7: Completed in 0.75 sec - Pass 6 of 7: Completed in 1.1 sec - Pass 7 of 7: Completed in 1.8 sec Evaluation completed in 8.5 sec
学習済みの木 Mdl
を表示します。
view(Mdl,'Mode','graph')
Mdl
は、深さ 8
の木です。
標本内平均二乗誤差を推定します。
MSE_Mdl = gather(loss(Mdl,tx,ty))
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 3.1 sec Evaluation completed in 3.7 sec
MSE_Mdl = 4.9078
すべての観測値を使用して回帰木を成長させます。最大の木の深さとして 4
を指定することにより、木の深さを制限します。
Mdl2 = fitrtree(tx,ty,'MaxDepth',4);
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 2: Completed in 0.38 sec - Pass 2 of 2: Completed in 0.35 sec Evaluation completed in 1.2 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.42 sec - Pass 2 of 7: Completed in 0.35 sec - Pass 3 of 7: Completed in 1.2 sec - Pass 4 of 7: Completed in 1.9 sec - Pass 5 of 7: Completed in 0.73 sec - Pass 6 of 7: Completed in 1.2 sec - Pass 7 of 7: Completed in 2.1 sec Evaluation completed in 8.9 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.44 sec - Pass 2 of 7: Completed in 0.39 sec - Pass 3 of 7: Completed in 1.1 sec - Pass 4 of 7: Completed in 2.1 sec - Pass 5 of 7: Completed in 0.74 sec - Pass 6 of 7: Completed in 1.1 sec - Pass 7 of 7: Completed in 2.7 sec Evaluation completed in 9.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.46 sec - Pass 2 of 7: Completed in 0.37 sec - Pass 3 of 7: Completed in 1.1 sec - Pass 4 of 7: Completed in 1.9 sec - Pass 5 of 7: Completed in 0.79 sec - Pass 6 of 7: Completed in 1.1 sec - Pass 7 of 7: Completed in 2.3 sec Evaluation completed in 9.1 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.43 sec - Pass 2 of 7: Completed in 0.41 sec - Pass 3 of 7: Completed in 1.1 sec - Pass 4 of 7: Completed in 1.9 sec - Pass 5 of 7: Completed in 0.72 sec - Pass 6 of 7: Completed in 1 sec - Pass 7 of 7: Completed in 2.2 sec Evaluation completed in 8.9 sec
学習済みの木 Mdl2
を表示します。
view(Mdl2,'Mode','graph')
標本内平均二乗誤差を推定します。
MSE_Mdl2 = gather(loss(Mdl2,tx,ty))
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.86 sec Evaluation completed in 1.3 sec
MSE_Mdl2 = 9.3903
Mdl2
は、複雑度が低くなった深さ 4 の木であり、標本内平均二乗誤差が Mdl
の平均二乗誤差より大きくなっています。
tall 配列を使用する回帰木のハイパーパラメーターを自動的に最適化します。標本データセットは carsmall
データセットです。この例では、データセットを tall 配列に変換して、最適化手順を実行するために使用します。
tall 配列に対する計算を実行する場合、MATLAB® は並列プール (Parallel Computing Toolbox™ がある場合は既定) またはローカルの MATLAB セッションを使用します。Parallel Computing Toolbox がある場合でもローカルの MATLAB セッションを使用して例を実行するには、関数mapreducer
を使用してグローバルな実行環境を変更できます。
carsmall
データセットを読み込みます。Displacement
、Horsepower
および Weight
が応答 MPG
の予測子であると考えます。
load carsmall
X = [Displacement Horsepower Weight];
インメモリ配列 X
および MPG
を tall 配列に変換します。
tx = tall(X);
Starting parallel pool (parpool) using the 'local' profile ... Connected to the parallel pool (number of workers: 6).
ty = tall(MPG);
名前と値のペアの引数 'OptimizeHyperparameters'
を使用して、自動的にハイパーパラメーターを最適化します。ホールドアウト交差検証損失が最小になる最適な 'MinLeafSize'
の値を求めます ('auto'
を指定すると 'MinLeafSize'
が使用されます)。再現性を得るため、'expected-improvement-plus'
の獲得関数を使用し、rng
と tallrng
により乱数発生器のシードを設定します。tall 配列の場合、ワーカーの個数と実行環境によって結果が異なる可能性があります。詳細については、コードの実行場所の制御を参照してください。
rng('default') tallrng('default') [Mdl,FitInfo,HyperparameterOptimizationResults] = fitrtree(tx,ty,... 'OptimizeHyperparameters','auto',... 'HyperparameterOptimizationOptions',struct('Holdout',0.3,... 'AcquisitionFunctionName','expected-improvement-plus'))
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 4.4 sec Evaluation completed in 6.2 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.97 sec - Pass 2 of 4: Completed in 1.6 sec - Pass 3 of 4: Completed in 3.6 sec - Pass 4 of 4: Completed in 2.4 sec Evaluation completed in 9.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.55 sec - Pass 2 of 4: Completed in 1.3 sec - Pass 3 of 4: Completed in 2.7 sec - Pass 4 of 4: Completed in 1.9 sec Evaluation completed in 7.3 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.52 sec - Pass 2 of 4: Completed in 1.3 sec - Pass 3 of 4: Completed in 3 sec - Pass 4 of 4: Completed in 2 sec Evaluation completed in 8.1 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.55 sec - Pass 2 of 4: Completed in 1.4 sec - Pass 3 of 4: Completed in 2.6 sec - Pass 4 of 4: Completed in 2 sec Evaluation completed in 7.3 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.61 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2.1 sec - Pass 4 of 4: Completed in 1.7 sec Evaluation completed in 6.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.53 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2.4 sec - Pass 4 of 4: Completed in 1.6 sec Evaluation completed in 6.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 1.4 sec Evaluation completed in 1.7 sec |======================================================================================| | Iter | Eval | Objective: | Objective | BestSoFar | BestSoFar | MinLeafSize | | | result | log(1+loss) | runtime | (observed) | (estim.) | | |======================================================================================| | 1 | Best | 3.2007 | 69.013 | 3.2007 | 3.2007 | 2 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.52 sec Evaluation completed in 0.83 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.65 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 3 sec - Pass 4 of 4: Completed in 2 sec Evaluation completed in 8.3 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.79 sec Evaluation completed in 1 sec | 2 | Error | NaN | 13.772 | NaN | 3.2007 | 46 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.52 sec Evaluation completed in 0.81 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.57 sec - Pass 2 of 4: Completed in 1.3 sec - Pass 3 of 4: Completed in 2.2 sec - Pass 4 of 4: Completed in 1.7 sec Evaluation completed in 6.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2.7 sec - Pass 4 of 4: Completed in 1.7 sec Evaluation completed in 6.9 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.47 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 2.1 sec - Pass 4 of 4: Completed in 1.9 sec Evaluation completed in 6.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.72 sec Evaluation completed in 0.99 sec | 3 | Best | 3.1876 | 29.091 | 3.1876 | 3.1884 | 18 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.48 sec Evaluation completed in 0.76 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 5.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.54 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.46 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.64 sec Evaluation completed in 0.92 sec | 4 | Best | 2.9048 | 33.465 | 2.9048 | 2.9537 | 6 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.44 sec Evaluation completed in 0.71 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.46 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 5.9 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.47 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.66 sec Evaluation completed in 0.92 sec | 5 | Accept | 3.2895 | 25.902 | 2.9048 | 2.9048 | 15 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.54 sec Evaluation completed in 0.82 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.53 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 2.1 sec - Pass 4 of 4: Completed in 1.9 sec Evaluation completed in 6.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.49 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 2 sec Evaluation completed in 6.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.68 sec Evaluation completed in 0.99 sec | 6 | Accept | 3.1641 | 35.522 | 2.9048 | 3.1493 | 5 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.51 sec Evaluation completed in 0.79 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.67 sec - Pass 2 of 4: Completed in 1.3 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 6.2 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.4 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.46 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.63 sec Evaluation completed in 0.89 sec | 7 | Accept | 2.9048 | 33.755 | 2.9048 | 2.9048 | 6 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.45 sec Evaluation completed in 0.75 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.51 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2.2 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 6.1 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.49 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.46 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.68 sec Evaluation completed in 0.97 sec | 8 | Accept | 2.9522 | 33.362 | 2.9048 | 2.9048 | 7 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.42 sec Evaluation completed in 0.71 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.49 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.64 sec Evaluation completed in 0.9 sec | 9 | Accept | 2.9985 | 32.674 | 2.9048 | 2.9048 | 8 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.43 sec Evaluation completed in 0.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.47 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.56 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.47 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.6 sec Evaluation completed in 5.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.88 sec Evaluation completed in 1.2 sec | 10 | Accept | 3.0185 | 33.922 | 2.9048 | 2.9048 | 10 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.44 sec Evaluation completed in 0.74 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.46 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.6 sec Evaluation completed in 6.2 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.73 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 6.2 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.63 sec Evaluation completed in 0.88 sec | 11 | Accept | 3.2895 | 26.625 | 2.9048 | 2.9048 | 14 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.48 sec Evaluation completed in 0.78 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.51 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.65 sec Evaluation completed in 0.9 sec | 12 | Accept | 3.4798 | 18.111 | 2.9048 | 2.9049 | 31 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.44 sec Evaluation completed in 0.71 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.64 sec Evaluation completed in 0.91 sec | 13 | Accept | 3.2248 | 47.436 | 2.9048 | 2.9048 | 1 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.46 sec Evaluation completed in 0.74 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.6 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.57 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 2.6 sec - Pass 4 of 4: Completed in 1.6 sec Evaluation completed in 6.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.62 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.6 sec Evaluation completed in 6.1 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.61 sec Evaluation completed in 0.88 sec | 14 | Accept | 3.1498 | 42.062 | 2.9048 | 2.9048 | 3 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.46 sec Evaluation completed in 0.76 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.67 sec - Pass 2 of 4: Completed in 1.3 sec - Pass 3 of 4: Completed in 2.3 sec - Pass 4 of 4: Completed in 2.2 sec Evaluation completed in 7.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.6 sec Evaluation completed in 0.86 sec | 15 | Accept | 2.9048 | 34.3 | 2.9048 | 2.9048 | 6 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.48 sec Evaluation completed in 0.78 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 2 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.62 sec Evaluation completed in 0.88 sec | 16 | Accept | 2.9048 | 32.97 | 2.9048 | 2.9048 | 6 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.43 sec Evaluation completed in 0.73 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.47 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.62 sec Evaluation completed in 0.9 sec | 17 | Accept | 3.1847 | 17.47 | 2.9048 | 2.9048 | 23 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.43 sec Evaluation completed in 0.72 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.68 sec - Pass 2 of 4: Completed in 1.4 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 6.3 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.62 sec Evaluation completed in 0.93 sec | 18 | Accept | 3.1817 | 33.346 | 2.9048 | 2.9048 | 4 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.43 sec Evaluation completed in 0.72 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.62 sec Evaluation completed in 0.86 sec | 19 | Error | NaN | 10.235 | 2.9048 | 2.9048 | 38 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.47 sec Evaluation completed in 0.76 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.63 sec Evaluation completed in 0.89 sec | 20 | Accept | 3.0628 | 32.459 | 2.9048 | 2.9048 | 12 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.46 sec Evaluation completed in 0.76 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.48 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.68 sec - Pass 2 of 4: Completed in 1.7 sec - Pass 3 of 4: Completed in 2.1 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 6.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.64 sec Evaluation completed in 0.9 sec |======================================================================================| | Iter | Eval | Objective: | Objective | BestSoFar | BestSoFar | MinLeafSize | | | result | log(1+loss) | runtime | (observed) | (estim.) | | |======================================================================================| | 21 | Accept | 3.1847 | 19.02 | 2.9048 | 2.9048 | 27 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.45 sec Evaluation completed in 0.75 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.47 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.5 sec - Pass 2 of 4: Completed in 1.6 sec - Pass 3 of 4: Completed in 2.4 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 6.8 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.5 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.63 sec Evaluation completed in 0.89 sec | 22 | Accept | 3.0185 | 33.933 | 2.9048 | 2.9048 | 9 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.46 sec Evaluation completed in 0.76 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.64 sec Evaluation completed in 0.89 sec | 23 | Accept | 3.0749 | 25.147 | 2.9048 | 2.9048 | 20 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.44 sec Evaluation completed in 0.73 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.42 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.53 sec - Pass 2 of 4: Completed in 1.4 sec - Pass 3 of 4: Completed in 1.9 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.9 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.62 sec Evaluation completed in 0.88 sec | 24 | Accept | 3.0628 | 32.764 | 2.9048 | 2.9048 | 11 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.44 sec Evaluation completed in 0.73 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.2 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.61 sec Evaluation completed in 0.87 sec | 25 | Error | NaN | 10.294 | 2.9048 | 2.9048 | 34 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.44 sec Evaluation completed in 0.73 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.62 sec Evaluation completed in 0.87 sec | 26 | Accept | 3.1847 | 17.587 | 2.9048 | 2.9048 | 25 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.45 sec Evaluation completed in 0.73 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.3 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.66 sec Evaluation completed in 0.96 sec | 27 | Accept | 3.2895 | 24.867 | 2.9048 | 2.9048 | 16 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.44 sec Evaluation completed in 0.74 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.4 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.6 sec Evaluation completed in 0.88 sec | 28 | Accept | 3.2135 | 24.928 | 2.9048 | 2.9048 | 13 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.47 sec Evaluation completed in 0.76 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.45 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.46 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.62 sec Evaluation completed in 0.87 sec | 29 | Accept | 3.1847 | 17.582 | 2.9048 | 2.9048 | 21 |
Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.53 sec Evaluation completed in 0.81 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.44 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 4: Completed in 0.43 sec - Pass 2 of 4: Completed in 1.1 sec - Pass 3 of 4: Completed in 1.8 sec - Pass 4 of 4: Completed in 1.3 sec Evaluation completed in 5.4 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 1: Completed in 0.63 sec Evaluation completed in 0.88 sec | 30 | Accept | 3.1827 | 17.597 | 2.9048 | 2.9122 | 29 |
__________________________________________________________ Optimization completed. MaxObjectiveEvaluations of 30 reached. Total function evaluations: 30 Total elapsed time: 882.5668 seconds. Total objective function evaluation time: 859.2122 Best observed feasible point: MinLeafSize ___________ 6 Observed objective function value = 2.9048 Estimated objective function value = 2.9122 Function evaluation time = 33.4655 Best estimated feasible point (according to models): MinLeafSize ___________ 6 Estimated objective function value = 2.9122 Estimated function evaluation time = 33.6594 Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 2: Completed in 0.26 sec - Pass 2 of 2: Completed in 0.26 sec Evaluation completed in 0.84 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.31 sec - Pass 2 of 7: Completed in 0.25 sec - Pass 3 of 7: Completed in 0.75 sec - Pass 4 of 7: Completed in 1.2 sec - Pass 5 of 7: Completed in 0.45 sec - Pass 6 of 7: Completed in 0.69 sec - Pass 7 of 7: Completed in 1.2 sec Evaluation completed in 5.7 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.28 sec - Pass 2 of 7: Completed in 0.24 sec - Pass 3 of 7: Completed in 0.75 sec - Pass 4 of 7: Completed in 1.2 sec - Pass 5 of 7: Completed in 0.46 sec - Pass 6 of 7: Completed in 0.67 sec - Pass 7 of 7: Completed in 1.2 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.32 sec - Pass 2 of 7: Completed in 0.25 sec - Pass 3 of 7: Completed in 0.71 sec - Pass 4 of 7: Completed in 1.2 sec - Pass 5 of 7: Completed in 0.47 sec - Pass 6 of 7: Completed in 0.66 sec - Pass 7 of 7: Completed in 1.2 sec Evaluation completed in 5.6 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.29 sec - Pass 2 of 7: Completed in 0.25 sec - Pass 3 of 7: Completed in 0.73 sec - Pass 4 of 7: Completed in 1.2 sec - Pass 5 of 7: Completed in 0.46 sec - Pass 6 of 7: Completed in 0.68 sec - Pass 7 of 7: Completed in 1.2 sec Evaluation completed in 5.5 sec Evaluating tall expression using the Parallel Pool 'local': - Pass 1 of 7: Completed in 0.27 sec - Pass 2 of 7: Completed in 0.25 sec - Pass 3 of 7: Completed in 0.75 sec - Pass 4 of 7: Completed in 1.2 sec - Pass 5 of 7: Completed in 0.47 sec - Pass 6 of 7: Completed in 0.69 sec - Pass 7 of 7: Completed in 1.2 sec Evaluation completed in 5.6 sec
Mdl = CompactRegressionTree ResponseName: 'Y' CategoricalPredictors: [] ResponseTransform: 'none' Properties, Methods
FitInfo = struct with no fields.
HyperparameterOptimizationResults = BayesianOptimization with properties: ObjectiveFcn: @createObjFcn/tallObjFcn VariableDescriptions: [3×1 optimizableVariable] Options: [1×1 struct] MinObjective: 2.9048 XAtMinObjective: [1×1 table] MinEstimatedObjective: 2.9122 XAtMinEstimatedObjective: [1×1 table] NumObjectiveEvaluations: 30 TotalElapsedTime: 882.5668 NextPoint: [1×1 table] XTrace: [30×1 table] ObjectiveTrace: [30×1 double] ConstraintsTrace: [] UserDataTrace: {30×1 cell} ObjectiveEvaluationTimeTrace: [30×1 double] IterationTimeTrace: [30×1 double] ErrorTrace: [30×1 double] FeasibilityTrace: [30×1 logical] FeasibilityProbabilityTrace: [30×1 double] IndexOfMinimumTrace: [30×1 double] ObjectiveMinimumTrace: [30×1 double] EstimatedObjectiveMinimumTrace: [30×1 double]
Tbl
— 標本データモデルを学習させるために使用する標本データ。テーブルとして指定します。Tbl
の各行は 1 つの観測値に、各列は 1 つの予測子変数に対応します。オプションとして、Tbl
に応答変数用の列を 1 つ追加できます。文字ベクトルの cell 配列ではない cell 配列と複数列の変数は使用できません。
Tbl
に応答変数が含まれている場合に Tbl
内の他の変数をすべて予測子として使用するには、ResponseVarName
を使用して応答変数を指定します。
Tbl
に応答変数が含まれている場合に Tbl
内の他の変数の一部のみを予測子として使用するには、formula
を使用して式を指定します。
Tbl
に応答変数が含まれていない場合は、Y
を使用して応答変数を指定します。応答変数の長さと Tbl
の行数は等しくなければなりません。
データ型: table
formula
— 応答変数および予測子変数サブセットの説明モデル応答変数および予測子変数サブセットの説明モデル。'Y~X1+X2+X3'
という形式の文字ベクトルまたは string スカラーを指定します。この式では、Y
は応答変数を、X1
、X2
および X3
は予測子変数を表します。
モデルに学習をさせるための予測子として Tbl
内の変数のサブセットを指定するには、式を使用します。式を指定した場合、formula
に現れない Tbl
内の変数は使用されません。
式の変数名は Tbl
の変数名 (Tbl.Properties.VariableNames
) であり、有効な MATLAB® 識別子でなければなりません。
関数 isvarname
を使用して Tbl
の変数名を検証できます。次のコードは、有効な変数名をもつ各変数の logical 1
(true
) を返します。
cellfun(@isvarname,Tbl.Properties.VariableNames)
Tbl
の変数名が有効ではない場合、関数 matlab.lang.makeValidName
を使用してそれらを変換します。Tbl.Properties.VariableNames = matlab.lang.makeValidName(Tbl.Properties.VariableNames);
データ型: char
| string
Y
— 応答データ応答データ。X
と同じ行数の数値列ベクトルとして指定します。Y
の各エントリは X
の対応する行に対する応答です。
Y
の NaN
値は欠損値と見なされます。fitrtree
は、Y
に欠損値がある観測値をあてはめで使用しません。
データ型: single
| double
X
— 予測子データ予測子データ。数値行列として指定します。X
の各列が 1 つの変数を表し、各行が 1 つの観測値を表します。
fitrtree
は、X
の NaN
値を欠損値として認識します。fitrtree
は、すべての欠損値のある観測を X
の近似に使用しません。fitrtree
は、これらの観測が有効な値をもつ場合に変数の分割を検出するために、一部の欠損値のある観測を X
に使用します。
データ型: single
| double
オプションの Name,Value
引数のコンマ区切りペアを指定します。Name
は引数名で、Value
は対応する値です。Name
は引用符で囲まなければなりません。Name1,Value1,...,NameN,ValueN
のように、複数の名前と値のペアの引数を、任意の順番で指定できます。
'CrossVal','on','MinParentSize',30
は、枝ノードごとに最低 30 個の観測値をもつ交差検証回帰木を指定します。メモ
交差検証の名前と値のペアの引数を名前と値のペアの引数 'OptimizeHyperparameters'
と同時に使用することはできません。'OptimizeHyperparameters'
の場合の交差検証は、名前と値のペアの引数 'HyperparameterOptimizationOptions'
を使用することのみによって変更できます。
'CategoricalPredictors'
— カテゴリカル予測子のリスト'all'
カテゴリカル予測子のリスト。'CategoricalPredictors'
と次の表のいずれかの値から構成されるコンマ区切りのペアとして指定します。
値 | 説明 |
---|---|
正の整数のベクトル | ベクトルの各エントリは、カテゴリカル変数が含まれている予測子データ (X または Tbl ) の列に対応するインデックス値です。 |
logical ベクトル | true というエントリは、予測子データ (X または Tbl ) の対応する列がカテゴリカル変数であることを意味します。 |
文字行列 | 行列の各行は予測子変数の名前です。名前は PredictorNames のエントリに一致しなくてはなりません。文字行列の各行が同じ長さになるように、名前を余分な空白で埋めてください。 |
文字ベクトルの cell 配列または string 配列 | 配列の各要素は予測子変数の名前です。名前は PredictorNames のエントリに一致しなくてはなりません。 |
'all' | すべての予測子がカテゴリカルです。 |
既定では、予測子データがテーブル (Tbl
) 内にある場合、fitrtree
は、その変数が logical ベクトル、順序付けのない categorical ベクトル、文字配列、string 配列または文字ベクトルの cell 配列のいずれかである場合に、変数を categorical であると見なします。予測子データが行列 (X
) である場合、fitrtree
はすべての予測子が連続的であると見なします。他の予測子をカテゴリカル予測子として指定するには、名前と値のペアの引数 'CategoricalPredictors'
を使用してそれらを指定します。
例: 'CategoricalPredictors','all'
データ型: single
| double
| logical
| char
| string
| cell
'MaxDepth'
— 最大の木の深さ最大の木の深さ。'MaxDepth'
と正の整数から構成されるコンマ区切りのペアとして指定します。この引数の値を指定すると、レベル数が少なく、計算対象の tall 配列に対して必要な通過回数が少ない木が返されます。一般に、fitrtree
のアルゴリズムでは、データを 1 回通過し、木の各レベルに対してさらに 1 回ずつ通過します。既定では、この関数は最大の木の深さを設定しません。
メモ
このオプションは、tall 配列に対して fitrtree
を使用する場合のみ適用されます。詳細については、tall 配列を参照してください。
'MergeLeaves'
— 葉マージ フラグ'on'
(既定値) | 'off'
葉マージ フラグ。'MergeLeaves'
と 'on'
または 'off'
で構成されるコンマ区切りのペアとして指定します。
MergeLeaves
が 'on'
の場合、fitrtree
は
同じ親ノードから派生する葉のうち、リスク値の合計が親ノードに関連付けられているリスク以上であるものをマージします。
枝刈りされた部分木の最適系列を推定しますが、回帰木は枝刈りしない
それ以外の場合、fitrtree
は葉をマージしません。
例: 'MergeLeaves','off'
'MinParentSize'
— 枝ノードの観測値の最小数10
(既定値) | 正の整数値枝ノードの観測値の最小数。'MinParentSize'
と正の整数値で構成されるコンマ区切りのペアとして指定します。ツリーの各枝ノードには少なくとも MinParentSize
の観測値があります。MinParentSize
と MinLeafSize
の両方を指定した場合、fitrtree
では葉の数が多くなる方の設定を使用します。MinParentSize = max(MinParentSize,2*MinLeafSize)
例: 'MinParentSize',8
データ型: single
| double
'NumBins'
— 数値予測子のビンの個数[]
(空) (既定値) | 正の整数スカラー数値予測子のビンの個数。'NumBins'
と正の整数スカラーから構成されるコンマ区切りのペアとして指定します。
'NumBins'
の値が空 (既定) である場合、どの予測子もビン化されません。
'NumBins'
の値として正の整数スカラーを指定した場合、指定した個数の同確率のビンにすべての数値予測子がビン化され、元のデータではなくビンのインデックスに対して木が成長します。
'NumBins'
の値が一意な予測子の値の個数 (u) を超える場合、fitrtree
は u 個のビンに予測子をビン化します。
fitrtree
は、カテゴリカル予測子をビン化しません。
大規模な学習データセットを使用する場合、このビン化オプションを使用すると学習を高速化できますが、精度が低下する可能性があります。はじめに 'NumBins',50
を試してから、精度と学習速度に応じて 'NumBins'
の値を変更できます。
学習済みのモデルでは、ビンのエッジは BinEdges
プロパティに格納されます。
例: 'NumBins',50
データ型: single
| double
'PredictorNames'
— 予測子変数名予測子変数名。'PredictorNames'
と一意な名前の string 配列または一意な文字ベクトルの cell 配列から構成されるコンマ区切りのペアとして指定します。'PredictorNames'
の機能は、学習データの提供方法によって決まります。
X
と Y
を指定した場合、'PredictorNames'
を使用して X
内の予測子変数に名前を割り当てることができます。
PredictorNames
内の名前の順序は、X
の列の順序に一致しなければなりません。つまり、PredictorNames{1}
は X(:,1)
の名前、PredictorNames{2}
は X(:,2)
の名前であり、他も同様です。また、size(X,2)
と numel(PredictorNames)
は等しくなければなりません。
既定では PredictorNames
は {'x1','x2',...}
です。
Tbl
が与えられた場合、'PredictorNames'
を使用して学習に使用する予測子変数を選択できます。つまり、fitrtree
は、学習中に PredictorNames
の予測子変数と応答変数のみを使用します。
PredictorNames
は Tbl.Properties.VariableNames
のサブセットでなければならず、応答変数の名前を含めることはできません。
既定では、すべての予測子変数の名前が PredictorNames
に格納されます。
'PredictorNames'
と formula
の両方ではなく、いずれか一方を使用して学習用の予測子を指定することをお勧めします。
例: 'PredictorNames',{'SepalLength','SepalWidth','PetalLength','PetalWidth'}
データ型: string
| cell
'PredictorSelection'
— 最適な分割予測子の選択に使用するアルゴリズム'allsplits'
(既定値) | 'curvature'
| 'interaction-curvature'
各ノードで最適な分割予測子の選択に使用するアルゴリズム。'PredictorSelection'
と次の表の値から構成されるコンマ区切りのペアとして指定します。
値 | 説明 |
---|---|
'allsplits' | 標準 CART — すべての予測子に対して可能なすべての分割について分割基準ゲインを最大化する分割予測子を選択します[1]。 |
'curvature' | 曲率検定 — 各予測子と応答の間の独立性に対するカイ二乗検定の p 値を最小化する分割予測子を選択します[2]。学習速度は標準 CART と同等です。 |
'interaction-curvature' | 交互作用検定 — 各予測子と応答の間の独立性に対するカイ二乗検定の p 値を最小化し (つまり、曲率検定を実施し)、予測子の各ペアと応答の間の独立性に対するカイ二乗検定の p 値を最小化する分割予測子を選択します[2]。学習速度は標準 CART より遅くなる可能性があります。 |
'curvature'
と 'interaction-curvature'
では、すべての検定で p 値が 0.05 を超える場合、fitrtree
はノードの分割を停止します。
ヒント
標準 CART アルゴリズムには、相違する値が少ない分割予測子 (カテゴリカル変数など) よりも、相違する値が多い分割予測子 (連続変数など) を選択する傾向があります[3]。以下のいずれかに該当する場合は、曲率検定または交互作用検定の指定を検討してください。
相違する値の個数が他の予測子よりも比較的少ない予測子がある場合 (予測子データセットが異種混合である場合など)。
予測子の重要度の分析が目標である場合。予測子の重要度推定の詳細については、predictorImportance
および特徴選択の紹介を参照してください。
標準 CART を使用して成長させた木は、予測子変数の交互作用の影響を受けません。また、多くの無関係な予測子が存在する状況では、このような木によって重要な変数が特定される可能性は、交互作用検定を適用した場合より低くなります。このため、予測子の交互作用を考慮し、重要度変数の特定を多くの無関係な変数が存在する状況で行うには、交互作用検定を指定します。
'PredictorSelection'
の値は、予測速度に影響を与えません。
fitrtree
が分割予測子を選択する方法の詳細については、ノード分割規則と分割予測子選択手法の選択を参照してください。
例: 'PredictorSelection','curvature'
'Prune'
— 枝刈りされた部分木の最適シーケンスを推定するフラグ'on'
(既定値) | 'off'
枝刈りされた部分木の最適なシーケンスを推定するフラグ。'Prune'
と 'on'
または 'off'
で構成されるコンマ区切りのペアとして指定します。
Prune
が 'on'
の場合、fitrtree
は回帰木を成長させ、枝刈りされた部分木の最適シーケンスを推定しますが、回帰木を枝刈りしません。それ以外の場合、fitrtree
は回帰木を成長させますが、枝刈りされた部分木の最適なシーケンスを推定しません。
学習させた回帰木を枝刈りするには、回帰木を prune
に渡します。
例: 'Prune','off'
'PruneCriterion'
— 枝刈り条件'mse'
(既定値)枝刈り条件。'PruneCriterion'
と 'mse'
で構成されるコンマ区切りのペアとして指定します。
'QuadraticErrorTolerance'
— 二次誤差の許容誤差1e-6
(既定値) | 正のスカラー値ノードあたりの二次誤差の許容誤差。'QuadraticErrorTolerance'
と正のスカラー値で構成されるコンマ区切りのペアとして指定します。ノードあたりの重み付き平均二乗誤差が QuadraticErrorTolerance*ε
より小さくなるとノード分割が停止します。ここで ε
は、決定木を成長させる前に計算された、n 個の応答すべての重み付き平均二乗誤差です。
wi は、すべての観測値の重みの合計が 1 になる () と仮定した場合の観測値 i の重みです。
は、すべての応答の加重平均です。
ノード分割の詳細については、ノード分割規則を参照してください。
例: 'QuadraticErrorTolerance',1e-4
'Reproducible'
— 再現性を強制するためのフラグfalse
(logical 0
) (既定値) | true
(logical 1
)モデルの学習の反復実行における再現性を強制するためのフラグ。'Reproducible'
と false
または true
から構成されるコンマ区切りのペアとして指定します。
'NumVariablesToSample'
が 'all'
ではない場合、各分岐で予測子が無作為に選択されます。無作為な選択を再現するには、'Reproducible',true
を指定し、rng
を使用して乱数発生器のシードを設定しなければなりません。'Reproducible'
を true
に設定すると学習速度が低下する可能性があることに注意してください。
例: 'Reproducible',true
データ型: logical
'ResponseName'
— 応答変数名'Y'
(既定値) | 文字ベクトル | string スカラー応答変数名。'ResponseName'
と文字ベクトルまたは string スカラーから構成されるコンマ区切りのペアとして指定します。
Y
を指定した場合、'ResponseName'
を使用して応答変数の名前を指定できます。
ResponseVarName
または formula
を指定した場合、'ResponseName'
を使用することはできません。
例: 'ResponseName','response'
データ型: char
| string
'ResponseTransform'
— 応答の変換'none'
(既定値) | 関数ハンドル応答の変換。'ResponseTransform'
と 'none'
または関数ハンドルのいずれかから構成されるコンマ区切りのペアとして指定します。既定の設定は 'none'
です。これは @(y)y
、つまり変換なしを表します。MATLAB 関数またはユーザー定義関数の場合は、関数ハンドルを使用します。関数ハンドルは、ベクトル (元の応答値) を受け入れて同じサイズのベクトル (変換した応答値) を返さなければなりません。
例: myfunction = @(y)exp(y)
を使用して、指数変換を入力ベクトルに適用する関数のハンドルを作成するとします。この場合、応答変換として 'ResponseTransform',myfunction
を指定できます。
データ型: char
| string
| function_handle
'SplitCriterion'
— 分割条件'MSE'
(既定値)分割条件。'SplitCriterion'
と 'MSE'
(平均二乗誤差) で構成されるコンマ区切りのペアとして指定します。
例: 'SplitCriterion','MSE'
'Surrogate'
— 代理決定分岐フラグ'off'
(既定値) | 'on'
| 'all'
| 正の整数代理決定分岐フラグ。'Surrogate'
と 'on'
、'off'
、'all'
または正の整数から構成されるコンマ区切りのペアとして指定します。
'on'
のときは、fitrtree
は各枝ノードで最大 10 の代理分岐を探します。
正の整数が設定された場合、fitrtree
は指定された数までの代理分岐を各枝ノードで検出します。
'all'
に設定すると、fitrtree
は各枝ノードですべての代理分岐を検出します。'all'
に設定すると、処理時間およびメモリ使用量が増加する可能性があります。
代理分岐を使用すると、欠損値をもつデータの予測精度が改善されます。また、予測子同士の関連性予測尺度も計算できます。
例: 'Surrogate','on'
データ型: single
| double
| char
| string
'Weights'
— 観測値の重みones(size(X,1),1)
(既定値) | スカラー値のベクトル | Tbl
内の変数の名前観測値の重み。'Weights'
とスカラー値のベクトルまたは Tbl
内の変数の名前から構成されるコンマ区切りのペアとして指定します。X
または Tbl
の各行に含まれている観測値には、Weights
の対応する値で重みが付けられます。Weights
のサイズは、X
または Tbl
の行数と同じでなければなりません。
入力データをテーブル Tbl
として指定した場合、Weights
は数値ベクトルが含まれている Tbl
内の変数の名前にすることができます。この場合、Weights
には文字ベクトルまたは string スカラーを指定しなければなりません。たとえば、重みのベクトル W
が Tbl.W
として格納されている場合、'W'
として指定します。それ以外の場合、モデルを学習させるときに、Tbl
の列は W
を含めてすべて予測子として扱われます。
fitrtree
は、合計が 1 になるように Weights
の値を正規化します。
データ型: single
| double
| char
| string
'CrossVal'
— 交差検証フラグ'off'
(既定値) | 'on'
交差検証フラグ。'CrossVal'
と、'on'
または 'off'
で構成されるコンマ区切りのペアとして指定します。
'on'
の場合は、fitrtree
が10 分割交差検証決定木を成長させます。'KFold'
、'Holdout'
、'Leaveout'
または 'CVPartition'
名前と値のペアの引数のいずれかを使用してこの交差検証の設定をオーバーライドできます。交差検証木を作成する場合、一度に使用できるのは 4 つのオプション ('KFold'
、'Holdout'
、'Leaveout'
および 'CVPartition'
) のいずれか 1 つのみです。
または、crossval
メソッドを使用して、後で tree
に交差検証を実施します。
例: 'CrossVal','on'
'CVPartition'
— 交差検証木の分割cvpartition
オブジェクト交差検証決定木で使用する分割。'CVPartition'
と、cvpartition
を使用して作成されるオブジェクトで構成される、コンマ区切りのペアとして指定されます。
'CVPartition'
を使用する場合は、'KFold'
、'Holdout'
または 'Leaveout'
名前と値のペアの引数のいずれも使用できません。
'Holdout'
— ホールドアウト検証の対象データの比率0
(既定値) | [0,1]
の範囲のスカラー値ホールドアウト検証に使用されるデータの比率。'Holdout'
と、[0,1]
の範囲内のスカラー値から成るコンマ区切りのペアとして指定します。ホールドアウト検証は、データの指定部分をテストし、データの残りの部分を学習に使用します。
'Holdout'
を使用する場合は、'CVPartition'
、'KFold'
または 'Leaveout'
名前と値のペアの引数のいずれも使用できません。
例: 'Holdout',0.1
データ型: single
| double
'KFold'
— 分割の数10
(既定値) | 1 より大きい正の整数交差検証木で使用する分割の数。'KFold'
と 1 より大きい正の整数値から構成されるコンマ区切りのペアとして指定します。
'KFold'
を使用する場合は、'CVPartition'
、'Holdout'
または 'Leaveout'
名前と値のペアの引数のいずれも使用できません。
例: 'KFold',8
データ型: single
| double
'Leaveout'
— Leave-one-out 法の交差検証のフラグ'off'
(既定値) | 'on'
Leave-one-out 法の交差検証のフラグ。'Leaveout'
と 'on'
または 'off
で構成されるコンマ区切りのペアとして指定します。'on'
に設定すると、leave-one-out 法の交差検証を使用します。
'Leaveout'
を使用する場合は、'CVPartition'
、'Holdout'
または 'KFold'
名前と値のペアの引数のいずれも使用できません。
例: 'Leaveout','on'
'MaxNumSplits'
— 決定分岐の最大数size(X,1) - 1
(既定値) | 正の整数決定分岐 (枝ノード) の最大数。'MaxNumSplits'
と正の整数をコンマ区切りのペアとして指定します。fitrtree
では、枝ノードの数が MaxNumSplits
以下になるように分割します。分割の動作についての詳細は、木の深さの制御を参照してください。
例: 'MaxNumSplits',5
データ型: single
| double
'MinLeafSize'
— 葉ノードの観測値の最小数1
(既定値) | 正の整数値葉ノードの観測値の最小数。'MinLeafSize'
と正の整数値で構成されるコンマ区切りのペアとして指定します。各葉には少なくともツリー葉あたり MinLeafSize
の観測値があります。MinParentSize
と MinLeafSize
の両方を指定した場合、fitrtree
では葉の数が多くなる方の設定を使用します。MinParentSize = max(MinParentSize,2*MinLeafSize)
。
例: 'MinLeafSize',3
データ型: single
| double
'NumVariablesToSample'
— 各分割についてランダムに選択する予測子の数'all'
(既定値) | 正の整数値分割ごとにランダムに選択する予測子の数。'NumVariablesToSample'
と正の整数値で構成されるコンマ区切りのペアとして指定します。また、'all'
を指定すると、使用可能なすべての予測子が使用されます。
多数の予測子が学習データに含まれている場合に予測子の重要度を分析するには、'NumVariablesToSample'
として 'all'
を指定します。このようにしないと、重要度が過小評価されて一部の予測子が選択されない可能性があります。
無作為な選択を再現するには、rng
を使用して乱数発生器のシードを設定し、'Reproducible',true
を指定しなければなりません。
例: 'NumVariablesToSample',3
データ型: char
| string
| single
| double
'OptimizeHyperparameters'
— 最適化するパラメーター'none'
(既定値) | 'auto'
| 'all'
| 使用可能パラメーター名の string 配列または cell 配列 | optimizableVariable
オブジェクトのベクトル最適化するパラメーター。'OptimizeHyperparameters'
と次のいずれかから構成されるコンマ区切りのペアとして指定します。
'none'
— 最適化を行いません。
'auto'
— {'MinLeafSize'}
を使用します。
'all'
— すべての使用可能パラメーターを最適化します。
使用可能パラメーター名の string 配列または cell 配列。
optimizableVariable
オブジェクトのベクトル。通常は hyperparameters
の出力です。
最適化では、パラメーターを変化させることにより、fitrtree
の交差検証損失 (誤差) を最小化しようとします。交差検証のタイプおよびその他の最適化の側面を制御するには、名前と値のペア HyperparameterOptimizationOptions
を使用します。
メモ
'OptimizeHyperparameters'
の値は、他の名前と値のペアの引数を使用して設定した値より優先されます。たとえば、'OptimizeHyperparameters'
を 'auto'
に設定すると、'auto'
の値が適用されます。
fitrtree
では、以下のパラメーターを使用できます。
MaxNumSplits
— fitrtree
は、既定では範囲 [1,max(2,NumObservations-1)]
の対数スケールで、整数を探索します。
MinLeafSize
— fitrtree
は、既定では範囲 [1,max(2,floor(NumObservations/2))]
の対数スケールで、整数を探索します。
NumVariablesToSample
— fitrtree
は、このハイパーパラメーターについて最適化を行いません。NumVariablesToSample
をパラメーター名として渡しても、fitrtree
はすべての予測子を使用するだけです。ただし、fitrensemble
はこのハイパーパラメーターについて最適化を行います。
既定以外のパラメーターを設定するには、既定以外の値が含まれている optimizableVariable
オブジェクトのベクトルを渡します。たとえば、以下のようにします。
load carsmall params = hyperparameters('fitrtree',[Horsepower,Weight],MPG); params(1).Range = [1,30];
OptimizeHyperparameters
の値として params
を渡します。
既定では、コマンド ラインに反復表示が表示され、最適化のハイパーパラメーターの個数に従ってプロットが表示されます。最適化とプロットにおける目的関数は、回帰の場合は log(1 + cross-validation loss)、分類の場合は誤分類率です。反復表示を制御するには、名前と値のペアの引数 'HyperparameterOptimizationOptions'
の Verbose
フィールドを設定します。プロットを制御するには、名前と値のペアの引数 'HyperparameterOptimizationOptions'
の ShowPlots
フィールドを設定します。
たとえば、回帰木の最適化を参照してください。
例: 'auto'
'HyperparameterOptimizationOptions'
— 最適化のオプション最適化のオプション。'HyperparameterOptimizationOptions'
と構造体から構成されるコンマ区切りのペアとして指定します。この引数を指定すると、名前と値のペアの引数 OptimizeHyperparameters
の効果が変化します。この構造体のフィールドは、すべてオプションです。
フィールド名 | 値 | 既定の設定 |
---|---|---|
Optimizer |
| 'bayesopt' |
AcquisitionFunctionName |
オブジェクト関数のランタイムによって最適化が異なるので、名前に | 'expected-improvement-per-second-plus' |
MaxObjectiveEvaluations | 目的関数評価の最大数。 | 'bayesopt' または 'randomsearch' の場合は 30 、'gridsearch' の場合はグリッド全体 |
MaxTime | 制限時間。正の実数を指定します。制限時間の単位は、 | Inf |
NumGridDivisions | 'gridsearch' における各次元の値の個数。値は、各次元の値の個数を表す正の整数のベクトル、またはすべての次元に適用されるスカラーが可能です。カテゴリカル変数の場合、このフィールドは無視されます。 | 10 |
ShowPlots | プロットを表示するかどうかを示す論理値。true の場合、最良の目的関数の値が反復回数に対してプロットされます。1 つまたは 2 つの最適化パラメーターがあり、Optimizer が 'bayesopt' である場合、ShowPlots はパラメーターに対する目的関数のモデルのプロットも行います。 | true |
SaveIntermediateResults | Optimizer が 'bayesopt' である場合に結果を保存するかどうかを示す論理値。true の場合、'BayesoptResults' という名前のワークスペース変数が反復ごとに上書きされます。この変数は BayesianOptimization オブジェクトです。 | false |
Verbose | コマンド ラインへの表示。
詳細については、 | 1 |
UseParallel | ベイズ最適化を並列実行するかどうかを示す論理値。並列実行には Parallel Computing Toolbox™ が必要です。並列でのタイミングに再現性がないため、並列ベイズ最適化で再現性のある結果が生成されるとは限りません。詳細については、並列ベイズ最適化を参照してください。 | false |
Repartition | 反復ごとに交差検証を再分割するかどうかを示す論理値。 分割ノイズが考慮されるので、通常は | false |
以下の 3 つのフィールド名は 1 つだけ使用できます。 | ||
CVPartition | cvpartition によって作成される cvpartition オブジェクト。 | 交差検証フィールドが指定されていない場合 'Kfold',5 |
Holdout | ホールドアウトの比率を表す範囲 (0,1) のスカラー。 | |
Kfold | 1 より大きい整数。 |
例: 'HyperparameterOptimizationOptions',struct('MaxObjectiveEvaluations',60)
データ型: struct
tree
— 回帰木回帰木。回帰木オブジェクトとして返します。'Crossval'
、'KFold'
、'Holdout'
、'Leaveout'
または 'CVPartition'
オプションを使用すると、クラス RegressionPartitionedModel
のツリーが生成されます。予測に分割されたツリーは使用できないため、この種類のツリーには predict
メソッドがありません。
それ以外の場合、tree
のクラスは RegressionTree
で、predict
メソッドを使用して予測を行うことができます。
"曲率検定" は、2 つの変数に関連性がないという帰無仮説を評価する統計検定です。
予測子変数 x および y の間の曲率検定は、以下のプロセスを使用して実施されます。
x が連続である場合、四分位数に分割します。分割のどの部分に属するかに従って観測値をビン化するノミナル変数を作成します。欠損値がある場合は、そのための追加のビンを作成します。
分割した予測子の各レベル j = 1,...,J と応答のクラス k = 1,...,K について、クラス k における観測値の加重比率を計算します。
wi は観測値 i の重みで です。I はインジケーター関数、n は標本サイズです。すべての観測値の重みが同じである場合、 になります。njk は、クラス k に属している予測子のレベル j の予測子のレベル <varname>j</varname> の観測値の個数です。
検定統計量
を計算します。 は、レベル j で予測子が観測される周辺確率です。 は、クラス k が観測される周辺確率です。n が十分に大きい場合、t は自由度が (K - 1)(J - 1) の χ2 分布になります。
この検定の p 値が 0.05 未満である場合、x と y には関連性がないという帰無仮説が棄却されます。
標準 CART アルゴリズムには、各ノードにおける最適な分割予測子を決定するときに、レベル数の多い連続予測子を選択する傾向があります。このような選択は見せかけだけの場合があり、カテゴリカル予測子などのような、より少ないレベルのより重要な予測子を隠してしまう可能性があります。
標準 CART の代わりに曲率検定を適用して、各ノードにおける最適な分割予測子を決定することができます。この場合、最適な分割予測子変数は、各予測子と応答変数の間における曲率検定の有意な p 値 (0.05 未満) が最小になる変数です。このような選択は、各予測子のレベル数に対してロバストです。
"交互作用検定" は、予測子変数のペアと応答変数の間に交互作用がないという帰無仮説を評価する統計検定です。
y に関して予測子変数 x1 および x2 の関連性を評価する交互作用検定は、以下のプロセスを使用して実施されます。
x1 または x2 が連続である場合、その変数を四分位数に分割します。分割のどの部分に属するかに従って観測値をビン化するノミナル変数を作成します。欠損値がある場合は、そのための追加のビンを作成します。
x1 および x2 のどのレベルに属しているかに従ってインデックスを観測値 i に割り当てる、J = J1J2 個のレベルがあるノミナル変数 z を作成します。どの観測値にも対応しないレベルを z から削除します。
z と y の間で曲率検定を実施します。
決定木を成長させるときに、予測子のペア間に重要な交互作用があり、重要度が低い他の予測子がデータ内に多数あると、標準 CART は重要な交互作用を見逃す傾向があります。しかし、代わりに曲率検定と交互作用検定を実施して予測子を選択すると、重要な交互作用の検出が改善され、より正確な決定木が生成される可能性があります。
"関連性予測尺度" は、観測値を分割する決定規則間の類似度を示す値です。(木を成長させることによって求められる) 最適な分割に対して比較される、可能なすべての決定分岐の中で、最適な代理決定分岐は関連性予測尺度が最大になります。2 番目に最適な代理分岐は、関連性予測尺度が 2 番目に大きくなります。
xj と xk がそれぞれ予測子変数 j および k であり、j ≠ k であるとします。ノード t における最適な分割 xj < u と代理分岐 xk < v の間の関連性予測尺度は、次のようになります。
PL は、ノード t において xj < u となる観測値の比率です。添字 L は、ノード t の左の子を表します。
PR は、ノード t において xj ≥ u となる観測値の比率です。添字 R は、ノード t の右の子を表します。
は、ノード t において xj < u および xk < v となる観測値の比率です。
は、ノード t において xj ≥ u および xk ≥ v となる観測値の比率です。
xj または xk について欠損値がある観測値は、比率の計算に使用されません。
λjk は、(-∞,1] の値になります。λjk > 0 である場合、xk < v は xj < u の代理分岐として価値があります。
"代理決定分岐" は、決定木の特定のノードにおける最適な決定分岐の代わりになります。最適な分割は、木を成長させることによって求められます。代理分岐では、類似する予測子変数または相関関係がある予測子変数と分割基準を使用します。
ある観測値について最適な分割予測子の値が欠損している場合、その観測値は最適な代理予測子を使用して左または右の子ノードに送られます。観測値について最適な代理予測子の値も欠損している場合、その観測値は 2 番目に最適な代理予測子を使用して左または右の子ノードに送られます。3 番目以降についても同様です。分割候補は、関連性予測尺度の降順で並べ替えられます。
fitrtree
は、以下のプロセスを使用してノード t の分割方法を決定します。
標準 CART の場合 (つまり、PredictorSelection
が 'allpairs'
である場合)、すべての予測子 xi (i = 1,...,p) について以下を行います。
fitrtree
は、次の式を使用してノード t における応答の重み付き平均二乗誤差 (MSE) を計算します。
wj は観測値 j の重み、T はノード t におけるすべての観測値のインデックスの集合です。Weights
を指定しない場合、wj = 1/n になります。n は、標本サイズです。
fitrtree
は、次の式を使用して、観測値がノード t に含まれる確率を推定します。
fitrtree
は、xi を昇順で並べ替えます。並べ替えられた予測子の各要素は、分割候補または切り取り点です。fitrtree
は、欠損値に対応するインデックスを、分割されない集合 TU に記録します。
fitrtree
は、すべての分割候補で MSE の減少 (ΔI) を最大化することにより、xi を使用してノード t を分割する最適な方法を決定します。つまり、xi に含まれているすべての分割候補について、
fitrtree
は、ノード t に含まれている観測値を左と右の子ノード (それぞれ tL および tR) に分割します。
fitrtree
は ΔI を計算します。特定の分割候補について、集合 TL および TR 内の観測値のインデックスがそれぞれ tL および tR に含まれていると仮定します。
xi に欠損値が含まれていない場合、現在の分割候補における MSE の減少は次のようになります。
xi に欠損値が含まれている場合、観測値はランダムに欠損していると仮定され、MSE の減少は次のようになります。
T - TU は、ノード t に含まれている、欠損していないすべての観測値のインデックスの集合です。
代理決定分岐を使用する場合、次のようになります。
fitrtree
は、決定分岐 xj < u と可能なすべての決定分岐 xk < v (j ≠ k) の間で関連性予測尺度 を計算します。
fitrtree
は、最適な分割となる関連性予測尺度の降順に、可能な代替決定分岐を並べ替えます。代理分岐は、尺度が最大になる決定分岐です。
fitrtree
は、xi について代理分岐を使用して、欠損値が含まれている観測値を子ノードに割り当てます。代理予測子にも欠損値が含まれている場合、fitrtree
は他の代理がなくなるまで、尺度が 2 番目に大きいものから順番に決定分岐を使用します。fitrtree
は、ノード t で 2 つの異なる代理分岐を使用して 2 つの異なる観測値を分割することができます。たとえば、ノード t で予測子 xi (i ∉ {1,2}) について、予測子 x1 および x2 がそれぞれ最適および 2 番目に最適な代理であるとします。予測子 xi の観測値 m が欠損しており (つまり、xmi が欠損)、xm1 は欠損していない場合、x1 は観測値 xmi の代理予測子になります。観測値 x(m + 1),i と x(m + 1),1 が欠損しており、x(m + 1),2 は欠損していない場合、x2 は観測値 m + 1 の代理予測子になります。
fitrtree
は、適切な MSE の減少の式を使用します。つまり、fitrtree
が代理分岐を使用して、ノード t に含まれているすべての欠損観測値を子ノードに割り当てることができない場合、MSE の減少は ΔIU になります。それ以外の場合、fitrtree
は MSE の減少に ΔI を使用します。
fitrtree
は、MSE の減少が最大になる候補を選択します。
fitrtree
は、MSE の減少が最大になる切り取り点で予測子変数を分割します。
曲率検定の場合 (つまり、PredictorSelection
が 'curvature'
である場合)
fitrtree
は、ノード t のすべての観測値について残差 を計算します。 は、ノード t の応答の加重平均です。重みは、Weights
の観測値の重みです。
fitrtree
は、対応する残差の符号に従って観測値を 2 つのビンのいずれかに割り当てます。zt は、ノード t の観測値に対するビンの割り当てを格納するノミナル変数であるとします。
fitrtree
は、各予測子と zt の間で曲率検定を実施します。回帰木の場合、K = 2 です。
すべての p 値が 0.05 以上である場合、fitrtree
はノード t を分割しません。
最小の p 値が存在する場合、fitrtree
は対応する予測子を選択してノード t を分割します。
アンダーフローにより複数の p 値がゼロになる場合、fitrtree
は対応する予測子に標準 CART を適用して分割予測子を選択します。
fitrtree
は、分割予測子を選択した場合に、標準 CART を使用して切り取り点を選択します (標準 CART のプロセスの手順 4 を参照)。
交互作用検定の場合 (つまり、PredictorSelection
が 'interaction-curvature'
である場合)
fitrtree
は、ノード t の観測値について、各予測子と応答の間で曲率検定を、予測子の各ペアと応答の間で交互作用検定を実施します。
すべての p 値が 0.05 以上である場合、fitrtree
はノード t を分割しません。
曲率検定の結果により最小の p 値が存在する場合、fitrtree
は対応する予測子を選択してノード t を分割します。
交互作用検定の結果により最小の p 値が存在する場合、fitrtree
は対応する予測子のペアに対して標準 CART を使用して分割予測子を選択します。
アンダーフローにより複数の p 値がゼロになる場合、fitrtree
は対応する予測子に標準 CART を適用して分割予測子を選択します。
fitrtree
は、分割予測子を選択した場合に、標準 CART を使用して切り取り点を選択します (標準 CART のプロセスの手順 4 を参照)。
MergeLeaves
が 'on'
および PruneCriterion
が 'mse'
(これらの名前と値のペアの引数の既定値) の場合、枝刈りは MSE を使用して葉のみに適用されます。このように指定すると、MSE が 2 つの葉の MSE の合計を超えない同じ親ノードから派生する葉がマージされます。
MaxNumSplits
に対応するため、fitrtree
は現在の "レイヤー" に含まれているすべてのノードを分割してから枝ノードの数をカウントします。レイヤーとは、ルート ノードから同じ距離にあるノードの集合です。枝ノードの数が MaxNumSplits
を超えた場合、fitrtree
は以下の手順に従います。
現在のレイヤーに含まれている枝ノードが、最大でも MaxNumSplits
になるように、分割を解除する数を判断する。
不純度順に枝ノードを並べ替える。
適切ではない分岐の分割を解除する。
それまでに成長させた決定木を返す。
この手順に従うと、バランスが最大の木が生成されます。
次の条件のいずれかが満たされるまで、枝ノードをレイヤー単位で分割します。
MaxNumSplits
個の枝ノードが存在している。
推奨されている分割を行うと、少なくとも 1 つの枝ノードで観測値の数が MinParentSize
より少なくなる。
推奨される分割を行うと、少なくとも 1 つの葉ノードで観測値の数が MinLeafSize
より少なくなる。
レイヤー内で適切な分割を検出できない。つまり、現在の枝刈り基準 (PruneCriterion
参照) では、レイヤー内で推奨されている分割を行っても状況が改善されない。すべてのノードが純粋 (ノード内のすべての観測値が同じクラス) になるのは特殊なケースです。
PredictorSelection
の値が 'curvature'
または 'interaction-curvature'
の場合に、すべての検定で p 値が 0.05 を超える。
MaxNumSplits
と MinLeafSize
は、既定値で行われる分割に影響を与えません。'MaxNumSplits'
を設定した場合、MaxNumSplits
回の分割が発生する前に、MinParentSize
の値が原因となって分割が停止することもあります。
デュアルコア以上のシステムの場合、fitrtree
では Intel® スレッディング ビルディング ブロック (TBB) を使用して決定木の学習を並列化します。Intel TBB についての詳細は、https://software.intel.com/en-us/intel-tbb を参照してください。
[1] Breiman, L., J. Friedman, R. Olshen, and C. Stone. Classification and Regression Trees. Boca Raton, FL: CRC Press, 1984.
[2] Loh, W.Y. “Regression Trees with Unbiased Variable Selection and Interaction Detection.” Statistica Sinica, Vol. 12, 2002, pp. 361–386.
[3] Loh, W.Y. and Y.S. Shih. “Split Selection Methods for Classification Trees.” Statistica Sinica, Vol. 7, 1997, pp. 815–840.
使用上の注意事項および制限事項:
以下の構文がサポートされます。
tree = fitrtree(Tbl,Y)
tree = fitrtree(X,Y)
tree = fitrtree(___,Name,Value)
[tree,FitInfo,HyperparameterOptimizationResults] = fitrtree(___,Name,Value)
— 名前と値のペアの引数 'OptimizeHyperparameters'
が指定された場合、fitrtree
は追加の出力引数 FitInfo
および HyperparameterOptimizationResults
を返します。
tree
は CompactRegressionTree
オブジェクトなので、回帰木の学習で使用したデータは含まれていません。
出力引数 FitInfo
は、現在は将来の使用のために予約されている空の構造体配列です。
出力引数 HyperparameterOptimizationResults
は、ハイパーパラメーターの交差検証最適化を記述する値が関連付けられているハイパーパラメーターの table または BayesianOptimization
オブジェクトです。
モデルの作成時に名前と値のペアの引数 'OptimizeHyperparameters'
が空以外であった場合、'HyperparameterOptimizationResults'
は空以外になります。'HyperparameterOptimizationResults'
の値は、モデルの作成時に名前と値のペアの引数 'HyperparameterOptimizationOptions'
について指定した値に依存します。
'bayesopt'
(既定) を指定した場合、HyperparameterOptimizationResults
は BayesianOptimization
クラスのオブジェクトになります。
'gridsearch'
または 'randomsearch'
を指定した場合、HyperparameterOptimizationResults
は table になり、使用したハイパーパラメーター、観測された目的関数の値(交差検証損失)、および最低 (最良) から最高 (最悪) までの観測値の順位が格納されます。
以下の名前と値のペアの引数がサポートされます。
'CategoricalPredictors'
'HyperparameterOptimizationOptions'
— 交差検証として、tall 最適化では 'Holdout'
検証のみがサポートされます。たとえば、fitrtree(X,Y,'OptimizeHyperparameters','auto','HyperparameterOptimizationOptions',struct('Holdout',0.2))
を指定できます。
'MaxNumSplits'
— tall 最適化の場合、fitrtree
は範囲 [1,max(2,min(10000,NumObservations–1))]
の (既定では) 対数スケールで整数を探索します。
'MergeLeaves'
'MinLeafSize'
— tall 最適化の場合、fitrtree
は範囲 [1,max(2,floor(NumObservations/2))]
の (既定では) 対数スケールで整数を探索します。
'MinParentSize'
'NumVariablesToSample'
— tall 最適化の場合、fitrtree
は範囲 [1,max(2,NumPredictors)]
の整数を探索します。
'OptimizeHyperparameters'
'PredictorNames'
'QuadraticErrorTolerance'
'ResponseName'
'ResponseTransform'
'SplitCriterion'
'Weights'
以下は、tall 配列専用の追加の名前と値のペアの引数です。
'MaxDepth'
— 出力される木の最大の深さを指定する正の整数。この引数の値を指定すると、レベル数が少なく、計算対象の tall 配列に対して必要な通過回数が少ない木が返されます。一般に、fitrtree
のアルゴリズムでは、データを 1 回通過し、木の各レベルに対してさらに 1 回ずつ通過します。既定では、この関数は最大の木の深さを設定しません。
詳細は、tall 配列を参照してください。
ハイパーパラメーターの最適化を並列実行するため、この関数を呼び出すときに名前と値のペアの引数 'HyperparameterOptimizationOptions', struct('UseParallel',true)
を指定します。
並列的なハイパーパラメーターの最適化の詳細については、並列ベイズ最適化を参照してください。
並列計算の全般的な情報については、自動並列サポートを使用した MATLAB 関数の実行 (Parallel Computing Toolbox)を参照してください。
次の MATLAB コマンドに対応するリンクがクリックされました。
コマンドを MATLAB コマンド ウィンドウに入力して実行してください。Web ブラウザーは MATLAB コマンドをサポートしていません。
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
Select web siteYou can also select a web site from the following list:
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.