adding xgboost code

This commit is contained in:
mhjensen
2019-11-07 13:51:33 +01:00
parent 456a54ca01
commit cfd31bac47
71 changed files with 2692 additions and 1704 deletions
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -283,7 +283,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs008.html">9</a></li>
<li><a href="._DecisionTrees-bs009.html">10</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs001.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -288,7 +288,7 @@ given some assumptions, make predictions about the target feature value
<li><a href="._DecisionTrees-bs009.html">10</a></li>
<li><a href="._DecisionTrees-bs010.html">11</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs002.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -266,7 +266,7 @@ This tree was produced using the Wisconsin cancer data (discussed here as well,
<li><a href="._DecisionTrees-bs010.html">11</a></li>
<li><a href="._DecisionTrees-bs011.html">12</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs003.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -274,7 +274,7 @@ node.
<li><a href="._DecisionTrees-bs011.html">12</a></li>
<li><a href="._DecisionTrees-bs012.html">13</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs004.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -275,7 +275,7 @@ Then we are essentially done!
<li><a href="._DecisionTrees-bs012.html">13</a></li>
<li><a href="._DecisionTrees-bs013.html">14</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs005.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -354,7 +354,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs013.html">14</a></li>
<li><a href="._DecisionTrees-bs014.html">15</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs006.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -287,7 +287,7 @@ within box \( j \).
<li><a href="._DecisionTrees-bs014.html">15</a></li>
<li><a href="._DecisionTrees-bs015.html">16</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs007.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -279,7 +279,7 @@ better tree in some future step.
<li><a href="._DecisionTrees-bs015.html">16</a></li>
<li><a href="._DecisionTrees-bs016.html">17</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs008.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -312,7 +312,7 @@ region contains more than five observations.
<li><a href="._DecisionTrees-bs016.html">17</a></li>
<li><a href="._DecisionTrees-bs017.html">18</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs009.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -281,7 +281,7 @@ parameter \( \alpha \).
<li><a href="._DecisionTrees-bs017.html">18</a></li>
<li><a href="._DecisionTrees-bs018.html">19</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs010.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -294,7 +294,7 @@ subtree corresponding to \( \alpha \).
<li><a href="._DecisionTrees-bs018.html">19</a></li>
<li><a href="._DecisionTrees-bs019.html">20</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs011.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -290,7 +290,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs019.html">20</a></li>
<li><a href="._DecisionTrees-bs020.html">21</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs012.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -282,7 +282,7 @@ fall into that region.
<li><a href="._DecisionTrees-bs020.html">21</a></li>
<li><a href="._DecisionTrees-bs021.html">22</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs013.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -287,7 +287,7 @@ than is the classification error rate.
<li><a href="._DecisionTrees-bs021.html">22</a></li>
<li><a href="._DecisionTrees-bs022.html">23</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs014.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -313,7 +313,7 @@ $$
<li><a href="._DecisionTrees-bs022.html">23</a></li>
<li><a href="._DecisionTrees-bs023.html">24</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs015.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -304,7 +304,7 @@ os<span style="color: #666666">.</span>system(cmd)
<li><a href="._DecisionTrees-bs023.html">24</a></li>
<li><a href="._DecisionTrees-bs024.html">25</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs016.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -295,7 +295,7 @@ os<span style="color: #666666">.</span>system(cmd)
<li><a href="._DecisionTrees-bs024.html">25</a></li>
<li><a href="._DecisionTrees-bs025.html">26</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs017.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -278,7 +278,7 @@ We discuss both algorithms with applications here. The popular library <b>Scikit
<li><a href="._DecisionTrees-bs025.html">26</a></li>
<li><a href="._DecisionTrees-bs026.html">27</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs018.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -268,7 +268,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs026.html">27</a></li>
<li><a href="._DecisionTrees-bs027.html">28</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs019.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -268,7 +268,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs027.html">28</a></li>
<li><a href="._DecisionTrees-bs028.html">29</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs020.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -308,7 +308,7 @@ The table here summarizes the various attributes and
<li><a href="._DecisionTrees-bs028.html">29</a></li>
<li><a href="._DecisionTrees-bs029.html">30</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs021.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -339,7 +339,7 @@ os<span style="color: #666666">.</span>system(cmd)
<li><a href="._DecisionTrees-bs029.html">30</a></li>
<li><a href="._DecisionTrees-bs030.html">31</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs022.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -341,7 +341,7 @@ split <span style="color: #666666">=</span> get_split(dataset)
<li><a href="._DecisionTrees-bs030.html">31</a></li>
<li><a href="._DecisionTrees-bs031.html">32</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs023.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -299,7 +299,7 @@ attributes at each step while growing the tree.
<li><a href="._DecisionTrees-bs031.html">32</a></li>
<li><a href="._DecisionTrees-bs032.html">33</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs024.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -459,7 +459,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs032.html">33</a></li>
<li><a href="._DecisionTrees-bs033.html">34</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs025.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -312,7 +312,7 @@ deep_tree_clf<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<li><a href="._DecisionTrees-bs033.html">34</a></li>
<li><a href="._DecisionTrees-bs034.html">35</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs026.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -335,7 +335,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs034.html">35</a></li>
<li><a href="._DecisionTrees-bs035.html">36</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs027.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -291,7 +291,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs035.html">36</a></li>
<li><a href="._DecisionTrees-bs036.html">37</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs028.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -285,7 +285,7 @@ tree_reg<span style="color: #666666">.</span>fit(X, y)
<li><a href="._DecisionTrees-bs036.html">37</a></li>
<li><a href="._DecisionTrees-bs037.html">38</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs029.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -341,7 +341,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs037.html">38</a></li>
<li><a href="._DecisionTrees-bs038.html">39</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs030.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -277,7 +277,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs038.html">39</a></li>
<li><a href="._DecisionTrees-bs039.html">40</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs031.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -280,7 +280,7 @@ However, by aggregating many decision trees, using methods like bagging, random
<li><a href="._DecisionTrees-bs039.html">40</a></li>
<li><a href="._DecisionTrees-bs040.html">41</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs032.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -287,7 +287,7 @@ We discuss these methods here.
<li><a href="._DecisionTrees-bs040.html">41</a></li>
<li><a href="._DecisionTrees-bs041.html">42</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs033.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -271,7 +271,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs041.html">42</a></li>
<li><a href="._DecisionTrees-bs042.html">43</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs034.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -282,7 +282,7 @@ learning method.
<li><a href="._DecisionTrees-bs042.html">43</a></li>
<li><a href="._DecisionTrees-bs043.html">44</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs035.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -292,7 +292,7 @@ predictor, averaged over all \( B \) trees.
<li><a href="._DecisionTrees-bs043.html">44</a></li>
<li><a href="._DecisionTrees-bs044.html">45</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs036.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -283,7 +283,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs044.html">45</a></li>
<li><a href="._DecisionTrees-bs045.html">46</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs037.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -314,7 +314,7 @@ voting_clf<span style="color: #666666">.</span>fit(X_train, y_train)
<li><a href="._DecisionTrees-bs045.html">46</a></li>
<li><a href="._DecisionTrees-bs046.html">47</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs038.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -321,7 +321,7 @@ voting_clf<span style="color: #666666">.</span>fit(X_train, y_train)
<li><a href="._DecisionTrees-bs046.html">47</a></li>
<li><a href="._DecisionTrees-bs047.html">48</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs039.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -324,7 +324,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs047.html">48</a></li>
<li><a href="._DecisionTrees-bs048.html">49</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs040.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -323,7 +323,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs048.html">49</a></li>
<li><a href="._DecisionTrees-bs049.html">50</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs041.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,47 +240,62 @@ MathJax.Hub.Config({
<a name="part0041"></a>
<!-- !split -->
<h2 id="___sec40" class="anchor">Random forests </h2>
<h2 id="___sec40" class="anchor">Changing the Level of the Decision Tree </h2>
<p>
Random forests provide an improvement over bagged trees by way of a
small tweak that decorrelates the trees.
<p>
As in bagging, we build a
number of decision trees on bootstrapped training samples. But when
building these decision trees, each time a split in a tree is
considered, a random sample of \( m \) predictors is chosen as split
candidates from the full set of \( p \) predictors. The split is allowed to
use only one of those \( m \) predictors.
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">matplotlib.pyplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">plt</span>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">numpy</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">np</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> train_test_split
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.pipeline</span> <span style="color: #008000; font-weight: bold">import</span> make_pipeline
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.utils</span> <span style="color: #008000; font-weight: bold">import</span> resample
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.tree</span> <span style="color: #008000; font-weight: bold">import</span> DecisionTreeRegressor
<p>
A fresh sample of \( m \) predictors is
taken at each split, and typically we choose
n <span style="color: #666666">=</span> <span style="color: #666666">100</span>
n_boostraps <span style="color: #666666">=</span> <span style="color: #666666">100</span>
maxdepth <span style="color: #666666">=</span> <span style="color: #666666">8</span>
$$
m\approx \sqrt{p}.
$$
<span style="color: #408080; font-style: italic"># Make data set.</span>
x <span style="color: #666666">=</span> np<span style="color: #666666">.</span>linspace(<span style="color: #666666">-3</span>, <span style="color: #666666">3</span>, n)<span style="color: #666666">.</span>reshape(<span style="color: #666666">-1</span>, <span style="color: #666666">1</span>)
y <span style="color: #666666">=</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>x<span style="color: #666666">**2</span>) <span style="color: #666666">+</span> <span style="color: #666666">1.5</span> <span style="color: #666666">*</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>(x<span style="color: #666666">-2</span>)<span style="color: #666666">**2</span>)<span style="color: #666666">+</span> np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>normal(<span style="color: #666666">0</span>, <span style="color: #666666">0.1</span>, x<span style="color: #666666">.</span>shape)
error <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
bias <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
variance <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
polydegree <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
X_train, X_test, y_train, y_test <span style="color: #666666">=</span> train_test_split(x, y, test_size<span style="color: #666666">=0.2</span>)
<p>
In building a random forest, at
each split in the tree, the algorithm is not even allowed to consider
a majority of the available predictors.
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> StandardScaler
scaler <span style="color: #666666">=</span> StandardScaler()
scaler<span style="color: #666666">.</span>fit(X_train)
X_train_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_train)
X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_test)
<p>
The reason for this is rather clever. Suppose that there is one very
strong predictor in the data set, along with a number of other
moderately strong predictors. Then in the collection of bagged
variable importance random forest trees, most or all of the trees will
use this strong predictor in the top split. Consequently, all of the
bagged trees will look quite similar to each other. Hence the
predictions from the bagged trees will be highly correlated.
Unfortunately, averaging many highly correlated quantities does not
lead to as large of a reduction in variance as averaging many
uncorrelated quanti- ties. In particular, this means that bagging will
not lead to a substantial reduction in variance over a single tree in
this setting.
<span style="color: #008000; font-weight: bold">for</span> degree <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(<span style="color: #666666">1</span>,maxdepth):
model <span style="color: #666666">=</span> DecisionTreeRegressor(max_depth<span style="color: #666666">=</span>degree)
y_pred <span style="color: #666666">=</span> np<span style="color: #666666">.</span>empty((y_test<span style="color: #666666">.</span>shape[<span style="color: #666666">0</span>], n_boostraps))
<span style="color: #008000; font-weight: bold">for</span> i <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(n_boostraps):
x_, y_ <span style="color: #666666">=</span> resample(X_train_scaled, y_train)
model<span style="color: #666666">.</span>fit(x_, y_)
y_pred[:, i] <span style="color: #666666">=</span> model<span style="color: #666666">.</span>predict(X_test_scaled)<span style="color: #408080; font-style: italic">#.ravel()</span>
polydegree[degree] <span style="color: #666666">=</span> degree
error[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>mean((y_test <span style="color: #666666">-</span> y_pred)<span style="color: #666666">**2</span>, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
bias[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( (y_test <span style="color: #666666">-</span> np<span style="color: #666666">.</span>mean(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>))<span style="color: #666666">**2</span> )
variance[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>var(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Polynomial degree:&#39;</span>, degree)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Error:&#39;</span>, error[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;{} &gt;= {} + {} = {}&#39;</span><span style="color: #666666">.</span>format(error[degree], bias[degree], variance[degree], bias[degree]<span style="color: #666666">+</span>variance[degree]))
plt<span style="color: #666666">.</span>xlim(<span style="color: #666666">1</span>,maxdepth)
plt<span style="color: #666666">.</span>plot(polydegree, error, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Error&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, bias, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;bias&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, variance, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Variance&#39;</span>)
plt<span style="color: #666666">.</span>legend()
plt<span style="color: #666666">.</span>show()
</pre></div>
<p>
<p>
<!-- navigation buttons at the bottom of the page -->
@@ -307,7 +322,7 @@ this setting.
<li><a href="._DecisionTrees-bs049.html">50</a></li>
<li><a href="._DecisionTrees-bs050.html">51</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs042.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,30 +240,48 @@ MathJax.Hub.Config({
<a name="part0042"></a>
<!-- !split -->
<h2 id="___sec41" class="anchor">Random Forest Algorithm </h2>
The algorithm described here can be applied to both classification and regression problems.
<h2 id="___sec41" class="anchor">Random forests </h2>
<p>
We will grow of forest of say \( M \) trees.
Random forests provide an improvement over bagged trees by way of a
small tweak that decorrelates the trees.
<ol>
<li> For \( m=1:M \) we</li>
<p>
As in bagging, we build a
number of decision trees on bootstrapped training samples. But when
building these decision trees, each time a split in a tree is
considered, a random sample of \( m \) predictors is chosen as split
candidates from the full set of \( p \) predictors. The split is allowed to
use only one of those \( m \) predictors.
<ul>
<li> Draw a bootstrap sample of from the training data organized in our \( \boldsymbol{X} \) matrix.</li>
<li> We grow then a random forest tree \( T_m \) based on the bootstrapped data by repeating the steps outlined till we reach the maximum node size is reached</li>
<p>
A fresh sample of \( m \) predictors is
taken at each split, and typically we choose
<ol>
<li> we select \( m \le p \) varibales at random from the \( p \) predictors/features</li>
<li> pick the best split point among the \( m \) features using either the CART algorithm or the ID3 for classification and create a new node</li>
<li> split the node into daughter nodes</li>
</ol>
$$
m\approx \sqrt{p}.
$$
</ul>
<p>
In building a random forest, at
each split in the tree, the algorithm is not even allowed to consider
a majority of the available predictors.
<li> Output then the ensemble of trees \( \{T_m\}_1^{M} \) and make predictions for either a regression type of problem or a classification type of problem.</li>
</ol>
<p>
The reason for this is rather clever. Suppose that there is one very
strong predictor in the data set, along with a number of other
moderately strong predictors. Then in the collection of bagged
variable importance random forest trees, most or all of the trees will
use this strong predictor in the top split. Consequently, all of the
bagged trees will look quite similar to each other. Hence the
predictions from the bagged trees will be highly correlated.
Unfortunately, averaging many highly correlated quantities does not
lead to as large of a reduction in variance as averaging many
uncorrelated quanti- ties. In particular, this means that bagging will
not lead to a substantial reduction in variance over a single tree in
this setting.
<p>
<p>
<!-- navigation buttons at the bottom of the page -->
<ul class="pagination">
@@ -289,7 +307,7 @@ We will grow of forest of say \( M \) trees.
<li><a href="._DecisionTrees-bs050.html">51</a></li>
<li><a href="._DecisionTrees-bs051.html">52</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs043.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,77 +240,30 @@ MathJax.Hub.Config({
<a name="part0043"></a>
<!-- !split -->
<h2 id="___sec42" class="anchor">Random Forests Compared with other Methods on the Cancer Data </h2>
<h2 id="___sec42" class="anchor">Random Forest Algorithm </h2>
The algorithm described here can be applied to both classification and regression problems.
<p>
We will grow of forest of say \( M \) trees.
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">matplotlib.pyplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">plt</span>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">numpy</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">np</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> train_test_split
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.datasets</span> <span style="color: #008000; font-weight: bold">import</span> load_breast_cancer
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.svm</span> <span style="color: #008000; font-weight: bold">import</span> SVC
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.linear_model</span> <span style="color: #008000; font-weight: bold">import</span> LogisticRegression
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.tree</span> <span style="color: #008000; font-weight: bold">import</span> DecisionTreeClassifier
<ol>
<li> For \( m=1:M \) we</li>
<span style="color: #408080; font-style: italic"># Load the data</span>
cancer <span style="color: #666666">=</span> load_breast_cancer()
<ul>
<li> Draw a bootstrap sample of from the training data organized in our \( \boldsymbol{X} \) matrix.</li>
<li> We grow then a random forest tree \( T_m \) based on the bootstrapped data by repeating the steps outlined till we reach the maximum node size is reached</li>
X_train, X_test, y_train, y_test <span style="color: #666666">=</span> train_test_split(cancer<span style="color: #666666">.</span>data,cancer<span style="color: #666666">.</span>target,random_state<span style="color: #666666">=0</span>)
<span style="color: #008000; font-weight: bold">print</span>(X_train<span style="color: #666666">.</span>shape)
<span style="color: #008000; font-weight: bold">print</span>(X_test<span style="color: #666666">.</span>shape)
<span style="color: #408080; font-style: italic"># Logistic Regression</span>
logreg <span style="color: #666666">=</span> LogisticRegression(solver<span style="color: #666666">=</span><span style="color: #BA2121">&#39;lbfgs&#39;</span>)
logreg<span style="color: #666666">.</span>fit(X_train, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Logistic Regression: {:.2f}&quot;</span><span style="color: #666666">.</span>format(logreg<span style="color: #666666">.</span>score(X_test,y_test)))
<span style="color: #408080; font-style: italic"># Support vector machine</span>
svm <span style="color: #666666">=</span> SVC(gamma<span style="color: #666666">=</span><span style="color: #BA2121">&#39;auto&#39;</span>, C<span style="color: #666666">=100</span>)
svm<span style="color: #666666">.</span>fit(X_train, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with SVM: {:.2f}&quot;</span><span style="color: #666666">.</span>format(svm<span style="color: #666666">.</span>score(X_test,y_test)))
<span style="color: #408080; font-style: italic"># Decision Trees</span>
deep_tree_clf <span style="color: #666666">=</span> DecisionTreeClassifier(max_depth<span style="color: #666666">=</span><span style="color: #008000">None</span>)
deep_tree_clf<span style="color: #666666">.</span>fit(X_train, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Decision Trees: {:.2f}&quot;</span><span style="color: #666666">.</span>format(deep_tree_clf<span style="color: #666666">.</span>score(X_test,y_test)))
<span style="color: #408080; font-style: italic">#now scale the data</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> StandardScaler
scaler <span style="color: #666666">=</span> StandardScaler()
scaler<span style="color: #666666">.</span>fit(X_train)
X_train_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_train)
X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_test)
<span style="color: #408080; font-style: italic"># Logistic Regression</span>
logreg<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy Logistic Regression with scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(logreg<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<span style="color: #408080; font-style: italic"># Support Vector Machine</span>
svm<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy SVM with scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(logreg<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<span style="color: #408080; font-style: italic"># Decision Trees</span>
deep_tree_clf<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Decision Trees and scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(deep_tree_clf<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<ol>
<li> we select \( m \le p \) varibales at random from the \( p \) predictors/features</li>
<li> pick the best split point among the \( m \) features using either the CART algorithm or the ID3 for classification and create a new node</li>
<li> split the node into daughter nodes</li>
</ol>
</ul>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.ensemble</span> <span style="color: #008000; font-weight: bold">import</span> RandomForestClassifier
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> LabelEncoder
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> cross_validate
<span style="color: #408080; font-style: italic"># Data set not specificied</span>
<span style="color: #408080; font-style: italic">#Instantiate the model with 500 trees and entropy as splitting criteria</span>
Random_Forest_model <span style="color: #666666">=</span> RandomForestClassifier(n_estimators<span style="color: #666666">=500</span>,criterion<span style="color: #666666">=</span><span style="color: #BA2121">&quot;entropy&quot;</span>)
Random_Forest_model<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #408080; font-style: italic">#Cross validation</span>
accuracy <span style="color: #666666">=</span> cross_validate(Random_Forest_model,X_test_scaled,y_test,cv<span style="color: #666666">=10</span>)[<span style="color: #BA2121">&#39;test_score&#39;</span>]
<span style="color: #008000; font-weight: bold">print</span>(accuracy)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Random Forests and scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(Random_Forest_model<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<li> Output then the ensemble of trees \( \{T_m\}_1^{M} \) and make predictions for either a regression type of problem or a classification type of problem.</li>
</ol>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">scikitplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">skplt</span>
y_pred <span style="color: #666666">=</span> Random_Forest_model<span style="color: #666666">.</span>predict(X_test_scaled)
skplt<span style="color: #666666">.</span>metrics<span style="color: #666666">.</span>plot_confusion_matrix(y_test, y_pred, normalize<span style="color: #666666">=</span><span style="color: #008000">True</span>)
plt<span style="color: #666666">.</span>show()
y_probas <span style="color: #666666">=</span> Random_Forest_model<span style="color: #666666">.</span>predict_proba(X_test_scaled)
skplt<span style="color: #666666">.</span>metrics<span style="color: #666666">.</span>plot_roc(y_test, y_probas)
plt<span style="color: #666666">.</span>show()
skplt<span style="color: #666666">.</span>metrics<span style="color: #666666">.</span>plot_cumulative_gain(y_test, y_probas)
plt<span style="color: #666666">.</span>show()
</pre></div>
<p>
<p>
<!-- navigation buttons at the bottom of the page -->
<ul class="pagination">
@@ -336,7 +289,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs051.html">52</a></li>
<li><a href="._DecisionTrees-bs052.html">53</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs044.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,24 +240,75 @@ MathJax.Hub.Config({
<a name="part0044"></a>
<!-- !split -->
<h2 id="___sec43" class="anchor">Compare Bagging on Trees with Random Forests </h2>
<h2 id="___sec43" class="anchor">Random Forests Compared with other Methods on the Cancer Data </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>bag_clf <span style="color: #666666">=</span> BaggingClassifier(
DecisionTreeClassifier(splitter<span style="color: #666666">=</span><span style="color: #BA2121">&quot;random&quot;</span>, max_leaf_nodes<span style="color: #666666">=16</span>, random_state<span style="color: #666666">=42</span>),
n_estimators<span style="color: #666666">=500</span>, max_samples<span style="color: #666666">=1.0</span>, bootstrap<span style="color: #666666">=</span><span style="color: #008000">True</span>, n_jobs<span style="color: #666666">=-1</span>, random_state<span style="color: #666666">=42</span>)
</pre></div>
<p>
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">matplotlib.pyplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">plt</span>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">numpy</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">np</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> train_test_split
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.datasets</span> <span style="color: #008000; font-weight: bold">import</span> load_breast_cancer
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.svm</span> <span style="color: #008000; font-weight: bold">import</span> SVC
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.linear_model</span> <span style="color: #008000; font-weight: bold">import</span> LogisticRegression
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.tree</span> <span style="color: #008000; font-weight: bold">import</span> DecisionTreeClassifier
<span style="color: #408080; font-style: italic"># Load the data</span>
cancer <span style="color: #666666">=</span> load_breast_cancer()
X_train, X_test, y_train, y_test <span style="color: #666666">=</span> train_test_split(cancer<span style="color: #666666">.</span>data,cancer<span style="color: #666666">.</span>target,random_state<span style="color: #666666">=0</span>)
<span style="color: #008000; font-weight: bold">print</span>(X_train<span style="color: #666666">.</span>shape)
<span style="color: #008000; font-weight: bold">print</span>(X_test<span style="color: #666666">.</span>shape)
<span style="color: #408080; font-style: italic"># Logistic Regression</span>
logreg <span style="color: #666666">=</span> LogisticRegression(solver<span style="color: #666666">=</span><span style="color: #BA2121">&#39;lbfgs&#39;</span>)
logreg<span style="color: #666666">.</span>fit(X_train, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Logistic Regression: {:.2f}&quot;</span><span style="color: #666666">.</span>format(logreg<span style="color: #666666">.</span>score(X_test,y_test)))
<span style="color: #408080; font-style: italic"># Support vector machine</span>
svm <span style="color: #666666">=</span> SVC(gamma<span style="color: #666666">=</span><span style="color: #BA2121">&#39;auto&#39;</span>, C<span style="color: #666666">=100</span>)
svm<span style="color: #666666">.</span>fit(X_train, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with SVM: {:.2f}&quot;</span><span style="color: #666666">.</span>format(svm<span style="color: #666666">.</span>score(X_test,y_test)))
<span style="color: #408080; font-style: italic"># Decision Trees</span>
deep_tree_clf <span style="color: #666666">=</span> DecisionTreeClassifier(max_depth<span style="color: #666666">=</span><span style="color: #008000">None</span>)
deep_tree_clf<span style="color: #666666">.</span>fit(X_train, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Decision Trees: {:.2f}&quot;</span><span style="color: #666666">.</span>format(deep_tree_clf<span style="color: #666666">.</span>score(X_test,y_test)))
<span style="color: #408080; font-style: italic">#now scale the data</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> StandardScaler
scaler <span style="color: #666666">=</span> StandardScaler()
scaler<span style="color: #666666">.</span>fit(X_train)
X_train_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_train)
X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_test)
<span style="color: #408080; font-style: italic"># Logistic Regression</span>
logreg<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy Logistic Regression with scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(logreg<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<span style="color: #408080; font-style: italic"># Support Vector Machine</span>
svm<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy SVM with scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(logreg<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<span style="color: #408080; font-style: italic"># Decision Trees</span>
deep_tree_clf<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Decision Trees and scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(deep_tree_clf<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>bag_clf<span style="color: #666666">.</span>fit(X_train, y_train)
y_pred <span style="color: #666666">=</span> bag_clf<span style="color: #666666">.</span>predict(X_test)
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.ensemble</span> <span style="color: #008000; font-weight: bold">import</span> RandomForestClassifier
rnd_clf <span style="color: #666666">=</span> RandomForestClassifier(n_estimators<span style="color: #666666">=500</span>, max_leaf_nodes<span style="color: #666666">=16</span>, n_jobs<span style="color: #666666">=-1</span>, random_state<span style="color: #666666">=42</span>)
rnd_clf<span style="color: #666666">.</span>fit(X_train, y_train)
y_pred_rf <span style="color: #666666">=</span> rnd_clf<span style="color: #666666">.</span>predict(X_test)
np<span style="color: #666666">.</span>sum(y_pred <span style="color: #666666">==</span> y_pred_rf) <span style="color: #666666">/</span> <span style="color: #008000">len</span>(y_pred)
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> LabelEncoder
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> cross_validate
<span style="color: #408080; font-style: italic"># Data set not specificied</span>
<span style="color: #408080; font-style: italic">#Instantiate the model with 500 trees and entropy as splitting criteria</span>
Random_Forest_model <span style="color: #666666">=</span> RandomForestClassifier(n_estimators<span style="color: #666666">=500</span>,criterion<span style="color: #666666">=</span><span style="color: #BA2121">&quot;entropy&quot;</span>)
Random_Forest_model<span style="color: #666666">.</span>fit(X_train_scaled, y_train)
<span style="color: #408080; font-style: italic">#Cross validation</span>
accuracy <span style="color: #666666">=</span> cross_validate(Random_Forest_model,X_test_scaled,y_test,cv<span style="color: #666666">=10</span>)[<span style="color: #BA2121">&#39;test_score&#39;</span>]
<span style="color: #008000; font-weight: bold">print</span>(accuracy)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&quot;Test set accuracy with Random Forests and scaled data: {:.2f}&quot;</span><span style="color: #666666">.</span>format(Random_Forest_model<span style="color: #666666">.</span>score(X_test_scaled,y_test)))
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">scikitplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">skplt</span>
y_pred <span style="color: #666666">=</span> Random_Forest_model<span style="color: #666666">.</span>predict(X_test_scaled)
skplt<span style="color: #666666">.</span>metrics<span style="color: #666666">.</span>plot_confusion_matrix(y_test, y_pred, normalize<span style="color: #666666">=</span><span style="color: #008000">True</span>)
plt<span style="color: #666666">.</span>show()
y_probas <span style="color: #666666">=</span> Random_Forest_model<span style="color: #666666">.</span>predict_proba(X_test_scaled)
skplt<span style="color: #666666">.</span>metrics<span style="color: #666666">.</span>plot_roc(y_test, y_probas)
plt<span style="color: #666666">.</span>show()
skplt<span style="color: #666666">.</span>metrics<span style="color: #666666">.</span>plot_cumulative_gain(y_test, y_probas)
plt<span style="color: #666666">.</span>show()
</pre></div>
<p>
<p>
@@ -285,7 +336,7 @@ np<span style="color: #666666">.</span>sum(y_pred <span style="color: #666666">=
<li><a href="._DecisionTrees-bs052.html">53</a></li>
<li><a href="._DecisionTrees-bs053.html">54</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs045.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,62 +240,24 @@ MathJax.Hub.Config({
<a name="part0045"></a>
<!-- !split -->
<h2 id="___sec44" class="anchor">Bootstrap with Random Forests Instead of a Single Tree </h2>
<h2 id="___sec44" class="anchor">Compare Bagging on Trees with Random Forests </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">matplotlib.pyplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">plt</span>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">numpy</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">np</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> train_test_split
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.pipeline</span> <span style="color: #008000; font-weight: bold">import</span> make_pipeline
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.utils</span> <span style="color: #008000; font-weight: bold">import</span> resample
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.ensemble</span> <span style="color: #008000; font-weight: bold">import</span> RandomForestRegressor
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>bag_clf <span style="color: #666666">=</span> BaggingClassifier(
DecisionTreeClassifier(splitter<span style="color: #666666">=</span><span style="color: #BA2121">&quot;random&quot;</span>, max_leaf_nodes<span style="color: #666666">=16</span>, random_state<span style="color: #666666">=42</span>),
n_estimators<span style="color: #666666">=500</span>, max_samples<span style="color: #666666">=1.0</span>, bootstrap<span style="color: #666666">=</span><span style="color: #008000">True</span>, n_jobs<span style="color: #666666">=-1</span>, random_state<span style="color: #666666">=42</span>)
</pre></div>
<p>
np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>seed(<span style="color: #666666">2018</span>)
n <span style="color: #666666">=</span> <span style="color: #666666">40</span>
n_boostraps <span style="color: #666666">=</span> <span style="color: #666666">100</span>
maxdegree <span style="color: #666666">=</span> <span style="color: #666666">14</span>
<span style="color: #408080; font-style: italic"># Make data set.</span>
x <span style="color: #666666">=</span> np<span style="color: #666666">.</span>linspace(<span style="color: #666666">-3</span>, <span style="color: #666666">3</span>, n)<span style="color: #666666">.</span>reshape(<span style="color: #666666">-1</span>, <span style="color: #666666">1</span>)
y <span style="color: #666666">=</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>x<span style="color: #666666">**2</span>) <span style="color: #666666">+</span> <span style="color: #666666">1.5</span> <span style="color: #666666">*</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>(x<span style="color: #666666">-2</span>)<span style="color: #666666">**2</span>)<span style="color: #666666">+</span> np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>normal(<span style="color: #666666">0</span>, <span style="color: #666666">0.1</span>, x<span style="color: #666666">.</span>shape)
error <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
bias <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
variance <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
polydegree <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
X_train, X_test, y_train, y_test <span style="color: #666666">=</span> train_test_split(x, y, test_size<span style="color: #666666">=0.2</span>)
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> StandardScaler
scaler <span style="color: #666666">=</span> StandardScaler()
scaler<span style="color: #666666">.</span>fit(X_train)
X_train_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_train)
X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_test)
<span style="color: #008000; font-weight: bold">for</span> degree <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(maxdegree):
model <span style="color: #666666">=</span> RandomForestRegressor()
y_pred <span style="color: #666666">=</span> np<span style="color: #666666">.</span>empty((y_test<span style="color: #666666">.</span>shape[<span style="color: #666666">0</span>], n_boostraps))
<span style="color: #008000; font-weight: bold">for</span> i <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(n_boostraps):
x_, y_ <span style="color: #666666">=</span> resample(X_train_scaled, y_train)
model<span style="color: #666666">.</span>fit(x_, y_)
y_pred[:, i] <span style="color: #666666">=</span> model<span style="color: #666666">.</span>predict(X_test_scaled)<span style="color: #666666">.</span>ravel()
polydegree[degree] <span style="color: #666666">=</span> degree
error[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>mean((y_test <span style="color: #666666">-</span> y_pred)<span style="color: #666666">**2</span>, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
bias[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( (y_test <span style="color: #666666">-</span> np<span style="color: #666666">.</span>mean(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>))<span style="color: #666666">**2</span> )
variance[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>var(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Polynomial degree:&#39;</span>, degree)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Error:&#39;</span>, error[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;{} &gt;= {} + {} = {}&#39;</span><span style="color: #666666">.</span>format(error[degree], bias[degree], variance[degree], bias[degree]<span style="color: #666666">+</span>variance[degree]))
plt<span style="color: #666666">.</span>plot(polydegree, error, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Error&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, bias, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;bias&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, variance, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Variance&#39;</span>)
plt<span style="color: #666666">.</span>legend()
plt<span style="color: #666666">.</span>show()
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span>bag_clf<span style="color: #666666">.</span>fit(X_train, y_train)
y_pred <span style="color: #666666">=</span> bag_clf<span style="color: #666666">.</span>predict(X_test)
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.ensemble</span> <span style="color: #008000; font-weight: bold">import</span> RandomForestClassifier
rnd_clf <span style="color: #666666">=</span> RandomForestClassifier(n_estimators<span style="color: #666666">=500</span>, max_leaf_nodes<span style="color: #666666">=16</span>, n_jobs<span style="color: #666666">=-1</span>, random_state<span style="color: #666666">=42</span>)
rnd_clf<span style="color: #666666">.</span>fit(X_train, y_train)
y_pred_rf <span style="color: #666666">=</span> rnd_clf<span style="color: #666666">.</span>predict(X_test)
np<span style="color: #666666">.</span>sum(y_pred <span style="color: #666666">==</span> y_pred_rf) <span style="color: #666666">/</span> <span style="color: #008000">len</span>(y_pred)
</pre></div>
<p>
<p>
@@ -323,7 +285,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs053.html">54</a></li>
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs046.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,20 +240,63 @@ MathJax.Hub.Config({
<a name="part0046"></a>
<!-- !split -->
<h2 id="___sec45" class="anchor">Boosting, a Bird'e Eye </h2>
<h2 id="___sec45" class="anchor">Bootstrap with Random Forests Instead of a Single Tree, own Bagging </h2>
<p>
The basic idea is to combine weak classifiers in order to create a good
classifier. With a weak classifier we often intend a classifier which
produces results which are only slightly better than we would get by
random guesses.
<p>
This is done by applying in an iterative way a weak (or a standard
classifier like decision trees) to modify the data. In each iteration
we emphasize those observations which are misclassified by weighting
them with a factor.
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">matplotlib.pyplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">plt</span>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">numpy</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">np</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> train_test_split
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.pipeline</span> <span style="color: #008000; font-weight: bold">import</span> make_pipeline
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.utils</span> <span style="color: #008000; font-weight: bold">import</span> resample
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.ensemble</span> <span style="color: #008000; font-weight: bold">import</span> RandomForestRegressor
np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>seed(<span style="color: #666666">2018</span>)
n <span style="color: #666666">=</span> <span style="color: #666666">100</span>
n_boostraps <span style="color: #666666">=</span> <span style="color: #666666">100</span>
maxdegree <span style="color: #666666">=</span> <span style="color: #666666">14</span>
<span style="color: #408080; font-style: italic"># Make data set.</span>
x <span style="color: #666666">=</span> np<span style="color: #666666">.</span>linspace(<span style="color: #666666">-3</span>, <span style="color: #666666">3</span>, n)<span style="color: #666666">.</span>reshape(<span style="color: #666666">-1</span>, <span style="color: #666666">1</span>)
y <span style="color: #666666">=</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>x<span style="color: #666666">**2</span>) <span style="color: #666666">+</span> <span style="color: #666666">1.5</span> <span style="color: #666666">*</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>(x<span style="color: #666666">-2</span>)<span style="color: #666666">**2</span>)<span style="color: #666666">+</span> np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>normal(<span style="color: #666666">0</span>, <span style="color: #666666">0.1</span>, x<span style="color: #666666">.</span>shape)
error <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
bias <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
variance <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
polydegree <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
X_train, X_test, y_train, y_test <span style="color: #666666">=</span> train_test_split(x, y, test_size<span style="color: #666666">=0.2</span>)
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> StandardScaler
scaler <span style="color: #666666">=</span> StandardScaler()
scaler<span style="color: #666666">.</span>fit(X_train)
X_train_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_train)
X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_test)
<span style="color: #008000; font-weight: bold">for</span> degree <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(maxdegree):
model <span style="color: #666666">=</span> RandomForestRegressor()
y_pred <span style="color: #666666">=</span> np<span style="color: #666666">.</span>empty((y_test<span style="color: #666666">.</span>shape[<span style="color: #666666">0</span>], n_boostraps))
<span style="color: #008000; font-weight: bold">for</span> i <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(n_boostraps):
x_, y_ <span style="color: #666666">=</span> resample(X_train_scaled, y_train)
model<span style="color: #666666">.</span>fit(x_, y_<span style="color: #666666">.</span>ravel())
y_pred[:, i] <span style="color: #666666">=</span> model<span style="color: #666666">.</span>predict(X_test_scaled)<span style="color: #666666">.</span>ravel()
polydegree[degree] <span style="color: #666666">=</span> degree
error[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>mean((y_test <span style="color: #666666">-</span> y_pred)<span style="color: #666666">**2</span>, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
bias[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( (y_test <span style="color: #666666">-</span> np<span style="color: #666666">.</span>mean(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>))<span style="color: #666666">**2</span> )
variance[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>var(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Polynomial degree:&#39;</span>, degree)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Error:&#39;</span>, error[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;{} &gt;= {} + {} = {}&#39;</span><span style="color: #666666">.</span>format(error[degree], bias[degree], variance[degree], bias[degree]<span style="color: #666666">+</span>variance[degree]))
plt<span style="color: #666666">.</span>plot(polydegree, error, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Error&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, bias, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;bias&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, variance, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Variance&#39;</span>)
plt<span style="color: #666666">.</span>legend()
plt<span style="color: #666666">.</span>show()
</pre></div>
<p>
<p>
<!-- navigation buttons at the bottom of the page -->
@@ -280,7 +323,7 @@ them with a factor.
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs047.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,24 +240,19 @@ MathJax.Hub.Config({
<a name="part0047"></a>
<!-- !split -->
<h2 id="___sec46" class="anchor">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<h2 id="___sec46" class="anchor">Boosting, a Bird'e Eye </h2>
<p>
The algorithm here is rather straightforward. Assume that our weak
classifier is a decision tree and we consider a binary set of outputs
with \( y_i \in \{-1,1\} \) and \( i=0,1,2,\dots,n-1 \) as our set of
observations. Our design matrix is given in terms of the
feature/predictor vectors
\( \boldsymbol{X}=[\boldsymbol{x}_0\boldsymbol{x}_1\dots\boldsymbol{x}_{p-1} \). Finally, we define also a
classifier determined by our data via a function \( G(\boldsymbol{X}) \). This function tells us how well we are able to classify our outputs/targets \( \boldsymbol{y} \).
The basic idea is to combine weak classifiers in order to create a good
classifier. With a weak classifier we often intend a classifier which
produces results which are only slightly better than we would get by
random guesses.
<p>
We can then define the misclassification error \( \mathrm{err} \) as
$$
\mathrm{err}=\frac{1}{n}\sum_{i=0}^{n-1}I(y_i\ne G(\boldsymbol{X}_{i*}),
$$
where the function \( I() \) is one if we misclassify and zero if we classify correctly.
This is done by applying in an iterative way a weak (or a standard
classifier like decision trees) to modify the data. In each iteration
we emphasize those observations which are misclassified by weighting
them with a factor.
<p>
<p>
@@ -284,6 +279,8 @@ where the function \( I() \) is one if we misclassify and zero if we classify co
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs048.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,42 +240,24 @@ MathJax.Hub.Config({
<a name="part0048"></a>
<!-- !split -->
<h2 id="___sec47" class="anchor">Basic Steps of AdaBoost </h2>
<h2 id="___sec47" class="anchor">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<p>
With the above definitions we are now ready to set up the algorithm for AdaBoost.
The basic idea is to set up weights which will be used to scale the correctly classified and the misclassified cases.
<ol>
<li> We start by initializing all weights to \( w_i = 1/n \), with \( i=0,1,2,\dots n-1 \). It is to see then that \( \sum_{i=0}^{n-1}w_i = 1 \).</li>
<li> We rewrite the misclassification error as</li>
</ol>
The algorithm here is rather straightforward. Assume that our weak
classifier is a decision tree and we consider a binary set of outputs
with \( y_i \in \{-1,1\} \) and \( i=0,1,2,\dots,n-1 \) as our set of
observations. Our design matrix is given in terms of the
feature/predictor vectors
\( \boldsymbol{X}=[\boldsymbol{x}_0\boldsymbol{x}_1\dots\boldsymbol{x}_{p-1} \). Finally, we define also a
classifier determined by our data via a function \( G(\boldsymbol{X}) \). This function tells us how well we are able to classify our outputs/targets \( \boldsymbol{y} \).
<p>
We can then define the misclassification error \( \mathrm{err} \) as
$$
\mathrm{err}=\frac{\sum_{i=0}^{n-1}w_iI(y_i\ne G(\boldsymbol{X}_{i*})}{\sum_{i=0}^{n-1}w_i},
\mathrm{err}=\frac{1}{n}\sum_{i=0}^{n-1}I(y_i\ne G(\boldsymbol{X}_{i*}),
$$
<ol>
<li> Then we start looping over all attempts at classifying, namely we start an iterative process for \( m=1:M \), where \( M \) is the final number of classifications. Our given classifier could for example be a plain decision tree.
<ol type="a"></li>
<li> Fit thus a given classifier to the training using the weights \( w_i \).</li>
<li> Compute then \( \mathrm{err} \) and figure out which events are classified properly and which are classified wrongly.</li>
<li> Define a quantity $\alpha_{m} = \log{(1-\mathrm{err})/\mathrm{err}}</li>
<li> Set the new weights to $w_i = w_i\times \exp{(\alpha_m I(y_i\ne G(\boldsymbol{X}_{i*})}.</li>
</ol>
<li> Compute the new classifier $G(\boldsymbol{X})= \sum_{i=0}^{n-1}\alpha_m I(y_i\ne G(\boldsymbol{X}_{i*}).</li>
</ol>
For the iterations with \( m \le 2 \) the weights are modified
individually at each steps. The obersvations which were misclassified
at iteration \( m-1 \) have a weight which is larger than those which were
classified properly. As this proceeds, the observations which were
difficult to classifiy correctly are given a larger influence. Each
new classification step \( m \) is then forced to concentrate on those
observations that are missed in the previous iterations.
where the function \( I() \) is one if we misclassify and zero if we classify correctly.
<p>
<p>
@@ -301,6 +283,7 @@ observations that are missed in the previous iterations.
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs049.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -240,7 +240,42 @@ MathJax.Hub.Config({
<a name="part0049"></a>
<!-- !split -->
<h2 id="___sec48" class="anchor">Figure to Illustrate the Iterative Classification Process </h2>
<h2 id="___sec48" class="anchor">Basic Steps of AdaBoost </h2>
<p>
With the above definitions we are now ready to set up the algorithm for AdaBoost.
The basic idea is to set up weights which will be used to scale the correctly classified and the misclassified cases.
<ol>
<li> We start by initializing all weights to \( w_i = 1/n \), with \( i=0,1,2,\dots n-1 \). It is to see then that \( \sum_{i=0}^{n-1}w_i = 1 \).</li>
<li> We rewrite the misclassification error as</li>
</ol>
$$
\mathrm{err}=\frac{\sum_{i=0}^{n-1}w_iI(y_i\ne G(\boldsymbol{X}_{i*})}{\sum_{i=0}^{n-1}w_i},
$$
<ol>
<li> Then we start looping over all attempts at classifying, namely we start an iterative process for \( m=1:M \), where \( M \) is the final number of classifications. Our given classifier could for example be a plain decision tree.
<ol type="a"></li>
<li> Fit then a given classifier to the training using the weights \( w_i \).</li>
<li> Compute then \( \mathrm{err} \) and figure out which events are classified properly and which are classified wrongly.</li>
<li> Define a quantity $\alpha_{m} = \log{(1-\mathrm{err})/\mathrm{err}}</li>
<li> Set the new weights to $w_i = w_i\times \exp{(\alpha_m I(y_i\ne G(\boldsymbol{X}_{i*})}.</li>
</ol>
<li> Compute the new classifier $G(\boldsymbol{X})= \sum_{i=0}^{n-1}\alpha_m I(y_i\ne G(\boldsymbol{X}_{i*}).</li>
</ol>
For the iterations with \( m \le 2 \) the weights are modified
individually at each steps. The obersvations which were misclassified
at iteration \( m-1 \) have a weight which is larger than those which were
classified properly. As this proceeds, the observations which were
difficult to classifiy correctly are given a larger influence. Each
new classification step \( m \) is then forced to concentrate on those
observations that are missed in the previous iterations.
<p>
<p>
@@ -265,6 +300,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs050.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -302,6 +302,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs051.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -273,6 +273,7 @@ function was the least squares function.
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs052.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -283,6 +283,7 @@ The way we proceed in an iterative fashion is to
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs053.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -346,6 +346,7 @@ plt<span style="color: #666666">.</span>show()
<li><a href="._DecisionTrees-bs054.html">55</a></li>
<li><a href="._DecisionTrees-bs055.html">56</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs054.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -101,37 +101,36 @@ Automatically generated HTML file from DocOnce source
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -209,22 +208,23 @@ MathJax.Hub.Config({
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs038.html#___sec37" style="font-size: 80%;">Please, not the moons again! Voting and Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs039.html#___sec38" style="font-size: 80%;">Now Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs040.html#___sec39" style="font-size: 80%;">Making our own Bagging with Bootstrap</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Figure to Illustrate the Iterative Classification Process</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs041.html#___sec40" style="font-size: 80%;">Changing the Level of the Decision Tree</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs042.html#___sec41" style="font-size: 80%;">Random forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs043.html#___sec42" style="font-size: 80%;">Random Forest Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs044.html#___sec43" style="font-size: 80%;">Random Forests Compared with other Methods on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs045.html#___sec44" style="font-size: 80%;">Compare Bagging on Trees with Random Forests</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs046.html#___sec45" style="font-size: 80%;">Bootstrap with Random Forests Instead of a Single Tree, own Bagging</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs047.html#___sec46" style="font-size: 80%;">Boosting, a Bird'e Eye</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs048.html#___sec47" style="font-size: 80%;">Adaptive boosting: AdaBoost, Basic Algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs049.html#___sec48" style="font-size: 80%;">Basic Steps of AdaBoost</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs050.html#___sec49" style="font-size: 80%;">AdaBoost Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs051.html#___sec50" style="font-size: 80%;">Gradient boosting: Basics</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs052.html#___sec51" style="font-size: 80%;">Gradient Boosting, algorithm</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs053.html#___sec52" style="font-size: 80%;">Gradient Boosting, Examples</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs054.html#___sec53" style="font-size: 80%;">Gradient Boots with Early Stopping</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs055.html#___sec54" style="font-size: 80%;">XGBoost: Extreme Gradient Boosting</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs056.html#___sec55" style="font-size: 80%;">Regression Case</a></li>
<!-- navigation toc: --> <li><a href="._DecisionTrees-bs057.html#___sec56" style="font-size: 80%;">Xgboost on the Cancer Data</a></li>
</ul>
</li>
@@ -283,7 +283,7 @@ MathJax.Hub.Config({
<li><a href="._DecisionTrees-bs008.html">9</a></li>
<li><a href="._DecisionTrees-bs009.html">10</a></li>
<li><a href="">...</a></li>
<li><a href="._DecisionTrees-bs056.html">57</a></li>
<li><a href="._DecisionTrees-bs057.html">58</a></li>
<li><a href="._DecisionTrees-bs001.html">&raquo;</a></li>
</ul>
<!-- ------------------- end of main content --------------- -->
@@ -1777,7 +1777,67 @@ plt.show()
<section>
<h2 id="___sec40">Random forests </h2>
<h2 id="___sec40">Changing the Level of the Decision Tree </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
<div class="highlight" style="background: #eeeedd"><pre style="font-size: 80%; line-height: 125%"><span></span><span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">matplotlib.pyplot</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">plt</span>
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">numpy</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">np</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.model_selection</span> <span style="color: #8B008B; font-weight: bold">import</span> train_test_split
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.pipeline</span> <span style="color: #8B008B; font-weight: bold">import</span> make_pipeline
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.utils</span> <span style="color: #8B008B; font-weight: bold">import</span> resample
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.tree</span> <span style="color: #8B008B; font-weight: bold">import</span> DecisionTreeRegressor
n = <span style="color: #B452CD">100</span>
n_boostraps = <span style="color: #B452CD">100</span>
maxdepth = <span style="color: #B452CD">8</span>
<span style="color: #228B22"># Make data set.</span>
x = np.linspace(-<span style="color: #B452CD">3</span>, <span style="color: #B452CD">3</span>, n).reshape(-<span style="color: #B452CD">1</span>, <span style="color: #B452CD">1</span>)
y = np.exp(-x**<span style="color: #B452CD">2</span>) + <span style="color: #B452CD">1.5</span> * np.exp(-(x-<span style="color: #B452CD">2</span>)**<span style="color: #B452CD">2</span>)+ np.random.normal(<span style="color: #B452CD">0</span>, <span style="color: #B452CD">0.1</span>, x.shape)
error = np.zeros(maxdepth)
bias = np.zeros(maxdepth)
variance = np.zeros(maxdepth)
polydegree = np.zeros(maxdepth)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=<span style="color: #B452CD">0.2</span>)
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.preprocessing</span> <span style="color: #8B008B; font-weight: bold">import</span> StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
<span style="color: #8B008B; font-weight: bold">for</span> degree <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(<span style="color: #B452CD">1</span>,maxdepth):
model = DecisionTreeRegressor(max_depth=degree)
y_pred = np.empty((y_test.shape[<span style="color: #B452CD">0</span>], n_boostraps))
<span style="color: #8B008B; font-weight: bold">for</span> i <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled)<span style="color: #228B22">#.ravel()</span>
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**<span style="color: #B452CD">2</span>, axis=<span style="color: #B452CD">1</span>, keepdims=<span style="color: #658b00">True</span>) )
bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=<span style="color: #B452CD">1</span>, keepdims=<span style="color: #658b00">True</span>))**<span style="color: #B452CD">2</span> )
variance[degree] = np.mean( np.var(y_pred, axis=<span style="color: #B452CD">1</span>, keepdims=<span style="color: #658b00">True</span>) )
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Polynomial degree:&#39;</span>, degree)
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Error:&#39;</span>, error[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;{} &gt;= {} + {} = {}&#39;</span>.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.xlim(<span style="color: #B452CD">1</span>,maxdepth)
plt.plot(polydegree, error, label=<span style="color: #CD5555">&#39;Error&#39;</span>)
plt.plot(polydegree, bias, label=<span style="color: #CD5555">&#39;bias&#39;</span>)
plt.plot(polydegree, variance, label=<span style="color: #CD5555">&#39;Variance&#39;</span>)
plt.legend()
plt.show()
</pre></div>
</section>
<section>
<h2 id="___sec41">Random forests </h2>
<p>
Random forests provide an improvement over bagged trees by way of a
@@ -1823,7 +1883,7 @@ this setting.
<section>
<h2 id="___sec41">Random Forest Algorithm </h2>
<h2 id="___sec42">Random Forest Algorithm </h2>
The algorithm described here can be applied to both classification and regression problems.
<p>
@@ -1854,7 +1914,7 @@ We will grow of forest of say \( M \) trees.
<section>
<h2 id="___sec42">Random Forests Compared with other Methods on the Cancer Data </h2>
<h2 id="___sec43">Random Forests Compared with other Methods on the Cancer Data </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
@@ -1928,7 +1988,7 @@ plt.show()
<section>
<h2 id="___sec43">Compare Bagging on Trees with Random Forests </h2>
<h2 id="___sec44">Compare Bagging on Trees with Random Forests </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
@@ -1951,7 +2011,7 @@ np.sum(y_pred == y_pred_rf) / <span style="color: #658b00">len</span>(y_pred)
<section>
<h2 id="___sec44">Bootstrap with Random Forests Instead of a Single Tree </h2>
<h2 id="___sec45">Bootstrap with Random Forests Instead of a Single Tree, own Bagging </h2>
<p>
@@ -1965,7 +2025,7 @@ np.sum(y_pred == y_pred_rf) / <span style="color: #658b00">len</span>(y_pred)
np.random.seed(<span style="color: #B452CD">2018</span>)
n = <span style="color: #B452CD">40</span>
n = <span style="color: #B452CD">100</span>
n_boostraps = <span style="color: #B452CD">100</span>
maxdegree = <span style="color: #B452CD">14</span>
@@ -1989,7 +2049,7 @@ X_test_scaled = scaler.transform(X_test)
y_pred = np.empty((y_test.shape[<span style="color: #B452CD">0</span>], n_boostraps))
<span style="color: #8B008B; font-weight: bold">for</span> i <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
model.fit(x_, y_.ravel())
y_pred[:, i] = model.predict(X_test_scaled).ravel()
polydegree[degree] = degree
@@ -2012,7 +2072,7 @@ plt.show()
<section>
<h2 id="___sec45">Boosting, a Bird'e Eye </h2>
<h2 id="___sec46">Boosting, a Bird'e Eye </h2>
<p>
The basic idea is to combine weak classifiers in order to create a good
@@ -2029,7 +2089,7 @@ them with a factor.
<section>
<h2 id="___sec46">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<h2 id="___sec47">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<p>
The algorithm here is rather straightforward. Assume that our weak
@@ -2053,7 +2113,7 @@ where the function \( I() \) is one if we misclassify and zero if we classify co
<section>
<h2 id="___sec47">Basic Steps of AdaBoost </h2>
<h2 id="___sec48">Basic Steps of AdaBoost </h2>
<p>
With the above definitions we are now ready to set up the algorithm for AdaBoost.
@@ -2074,7 +2134,7 @@ $$
<p><li> Then we start looping over all attempts at classifying, namely we start an iterative process for \( m=1:M \), where \( M \) is the final number of classifications. Our given classifier could for example be a plain decision tree.
<ol type="a"></li>
<p><li> Fit thus a given classifier to the training using the weights \( w_i \).</li>
<p><li> Fit then a given classifier to the training using the weights \( w_i \).</li>
<p><li> Compute then \( \mathrm{err} \) and figure out which events are classified properly and which are classified wrongly.</li>
<p><li> Define a quantity $\alpha_{m} = \log{(1-\mathrm{err})/\mathrm{err}}</li>
<p><li> Set the new weights to $w_i = w_i\times \exp{(\alpha_m I(y_i\ne G(\boldsymbol{X}_{i*})}.</li>
@@ -2093,11 +2153,6 @@ observations that are missed in the previous iterations.
</section>
<section>
<h2 id="___sec48">Figure to Illustrate the Iterative Classification Process </h2>
</section>
<section>
<h2 id="___sec49">AdaBoost Examples </h2>
@@ -2363,7 +2418,63 @@ It is now the algorithm which wins essentially all ML competitions!!!
<section>
<h2 id="___sec55">Xgboost on the Cancer Data </h2>
<h2 id="___sec55">Regression Case </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
<div class="highlight" style="background: #eeeedd"><pre style="font-size: 80%; line-height: 125%"><span></span><span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">matplotlib.pyplot</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">plt</span>
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">numpy</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">np</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.model_selection</span> <span style="color: #8B008B; font-weight: bold">import</span> train_test_split
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">xgboost</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">xgb</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.preprocessing</span> <span style="color: #8B008B; font-weight: bold">import</span> StandardScaler
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">scikitplot</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">skplt</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.metrics</span> <span style="color: #8B008B; font-weight: bold">import</span> mean_squared_error
n = <span style="color: #B452CD">40</span>
n_boostraps = <span style="color: #B452CD">100</span>
maxdegree = <span style="color: #B452CD">8</span>
<span style="color: #228B22"># Make data set.</span>
x = np.linspace(-<span style="color: #B452CD">3</span>, <span style="color: #B452CD">3</span>, n).reshape(-<span style="color: #B452CD">1</span>, <span style="color: #B452CD">1</span>)
y = np.exp(-x**<span style="color: #B452CD">2</span>) + <span style="color: #B452CD">1.5</span> * np.exp(-(x-<span style="color: #B452CD">2</span>)**<span style="color: #B452CD">2</span>)+ np.random.normal(<span style="color: #B452CD">0</span>, <span style="color: #B452CD">0.1</span>, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
polydegree = np.zeros(maxdegree)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=<span style="color: #B452CD">0.2</span>)
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
<span style="color: #8B008B; font-weight: bold">for</span> degree <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(maxdegree):
model = xgb.XGBRegressor(objective =<span style="color: #CD5555">&#39;reg:linear&#39;</span>, colsample_bytree = <span style="color: #B452CD">0.3</span>, learning_rate = <span style="color: #B452CD">0.1</span>,
max_depth = maxdegree, alpha = <span style="color: #B452CD">10</span>, n_estimators = <span style="color: #B452CD">10</span>)
model.fit(X_train_scaled,y_train)
y_pred = model.predict(X_test_scaled)
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**<span style="color: #B452CD">2</span>) )
bias[degree] = np.mean( (y_test - np.mean(y_pred))**<span style="color: #B452CD">2</span> )
variance[degree] = np.mean( np.var(y_pred) )
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Max depth:&#39;</span>, degree)
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Error:&#39;</span>, error[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;{} &gt;= {} + {} = {}&#39;</span>.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.plot(polydegree, error, label=<span style="color: #CD5555">&#39;Error&#39;</span>)
plt.plot(polydegree, bias, label=<span style="color: #CD5555">&#39;bias&#39;</span>)
plt.plot(polydegree, variance, label=<span style="color: #CD5555">&#39;Variance&#39;</span>)
plt.legend()
plt.show()
</pre></div>
</section>
<section>
<h2 id="___sec56">Xgboost on the Cancer Data </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
@@ -121,37 +121,36 @@ div { text-align: justify; text-justify: inter-word; }
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -1776,7 +1775,66 @@ plt.show()
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec40">Random forests </h2>
<h2 id="___sec40">Changing the Level of the Decision Tree </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
<div class="highlight" style="background: #eeeedd"><pre style="line-height: 125%"><span></span><span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">matplotlib.pyplot</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">plt</span>
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">numpy</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">np</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.model_selection</span> <span style="color: #8B008B; font-weight: bold">import</span> train_test_split
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.pipeline</span> <span style="color: #8B008B; font-weight: bold">import</span> make_pipeline
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.utils</span> <span style="color: #8B008B; font-weight: bold">import</span> resample
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.tree</span> <span style="color: #8B008B; font-weight: bold">import</span> DecisionTreeRegressor
n = <span style="color: #B452CD">100</span>
n_boostraps = <span style="color: #B452CD">100</span>
maxdepth = <span style="color: #B452CD">8</span>
<span style="color: #228B22"># Make data set.</span>
x = np.linspace(-<span style="color: #B452CD">3</span>, <span style="color: #B452CD">3</span>, n).reshape(-<span style="color: #B452CD">1</span>, <span style="color: #B452CD">1</span>)
y = np.exp(-x**<span style="color: #B452CD">2</span>) + <span style="color: #B452CD">1.5</span> * np.exp(-(x-<span style="color: #B452CD">2</span>)**<span style="color: #B452CD">2</span>)+ np.random.normal(<span style="color: #B452CD">0</span>, <span style="color: #B452CD">0.1</span>, x.shape)
error = np.zeros(maxdepth)
bias = np.zeros(maxdepth)
variance = np.zeros(maxdepth)
polydegree = np.zeros(maxdepth)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=<span style="color: #B452CD">0.2</span>)
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.preprocessing</span> <span style="color: #8B008B; font-weight: bold">import</span> StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
<span style="color: #8B008B; font-weight: bold">for</span> degree <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(<span style="color: #B452CD">1</span>,maxdepth):
model = DecisionTreeRegressor(max_depth=degree)
y_pred = np.empty((y_test.shape[<span style="color: #B452CD">0</span>], n_boostraps))
<span style="color: #8B008B; font-weight: bold">for</span> i <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled)<span style="color: #228B22">#.ravel()</span>
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**<span style="color: #B452CD">2</span>, axis=<span style="color: #B452CD">1</span>, keepdims=<span style="color: #658b00">True</span>) )
bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=<span style="color: #B452CD">1</span>, keepdims=<span style="color: #658b00">True</span>))**<span style="color: #B452CD">2</span> )
variance[degree] = np.mean( np.var(y_pred, axis=<span style="color: #B452CD">1</span>, keepdims=<span style="color: #658b00">True</span>) )
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Polynomial degree:&#39;</span>, degree)
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Error:&#39;</span>, error[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;{} &gt;= {} + {} = {}&#39;</span>.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.xlim(<span style="color: #B452CD">1</span>,maxdepth)
plt.plot(polydegree, error, label=<span style="color: #CD5555">&#39;Error&#39;</span>)
plt.plot(polydegree, bias, label=<span style="color: #CD5555">&#39;bias&#39;</span>)
plt.plot(polydegree, variance, label=<span style="color: #CD5555">&#39;Variance&#39;</span>)
plt.legend()
plt.show()
</pre></div>
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec41">Random forests </h2>
<p>
Random forests provide an improvement over bagged trees by way of a
@@ -1820,7 +1878,7 @@ this setting.
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec41">Random Forest Algorithm </h2>
<h2 id="___sec42">Random Forest Algorithm </h2>
The algorithm described here can be applied to both classification and regression problems.
<p>
@@ -1846,7 +1904,7 @@ We will grow of forest of say \( M \) trees.
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec42">Random Forests Compared with other Methods on the Cancer Data </h2>
<h2 id="___sec43">Random Forests Compared with other Methods on the Cancer Data </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
@@ -1919,7 +1977,7 @@ plt.show()
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec43">Compare Bagging on Trees with Random Forests </h2>
<h2 id="___sec44">Compare Bagging on Trees with Random Forests </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
@@ -1941,7 +1999,7 @@ np.sum(y_pred == y_pred_rf) / <span style="color: #658b00">len</span>(y_pred)
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec44">Bootstrap with Random Forests Instead of a Single Tree </h2>
<h2 id="___sec45">Bootstrap with Random Forests Instead of a Single Tree, own Bagging </h2>
<p>
@@ -1955,7 +2013,7 @@ np.sum(y_pred == y_pred_rf) / <span style="color: #658b00">len</span>(y_pred)
np.random.seed(<span style="color: #B452CD">2018</span>)
n = <span style="color: #B452CD">40</span>
n = <span style="color: #B452CD">100</span>
n_boostraps = <span style="color: #B452CD">100</span>
maxdegree = <span style="color: #B452CD">14</span>
@@ -1979,7 +2037,7 @@ X_test_scaled = scaler.transform(X_test)
y_pred = np.empty((y_test.shape[<span style="color: #B452CD">0</span>], n_boostraps))
<span style="color: #8B008B; font-weight: bold">for</span> i <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
model.fit(x_, y_.ravel())
y_pred[:, i] = model.predict(X_test_scaled).ravel()
polydegree[degree] = degree
@@ -2001,7 +2059,7 @@ plt.show()
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec45">Boosting, a Bird'e Eye </h2>
<h2 id="___sec46">Boosting, a Bird'e Eye </h2>
<p>
The basic idea is to combine weak classifiers in order to create a good
@@ -2018,7 +2076,7 @@ them with a factor.
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec46">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<h2 id="___sec47">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<p>
The algorithm here is rather straightforward. Assume that our weak
@@ -2040,7 +2098,7 @@ where the function \( I() \) is one if we misclassify and zero if we classify co
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec47">Basic Steps of AdaBoost </h2>
<h2 id="___sec48">Basic Steps of AdaBoost </h2>
<p>
With the above definitions we are now ready to set up the algorithm for AdaBoost.
@@ -2060,7 +2118,7 @@ $$
<li> Then we start looping over all attempts at classifying, namely we start an iterative process for \( m=1:M \), where \( M \) is the final number of classifications. Our given classifier could for example be a plain decision tree.
<ol type="a"></li>
<li> Fit thus a given classifier to the training using the weights \( w_i \).</li>
<li> Fit then a given classifier to the training using the weights \( w_i \).</li>
<li> Compute then \( \mathrm{err} \) and figure out which events are classified properly and which are classified wrongly.</li>
<li> Define a quantity $\alpha_{m} = \log{(1-\mathrm{err})/\mathrm{err}}</li>
<li> Set the new weights to $w_i = w_i\times \exp{(\alpha_m I(y_i\ne G(\boldsymbol{X}_{i*})}.</li>
@@ -2080,11 +2138,6 @@ observations that are missed in the previous iterations.
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec48">Figure to Illustrate the Iterative Classification Process </h2>
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec49">AdaBoost Examples </h2>
<p>
@@ -2344,7 +2397,62 @@ It is now the algorithm which wins essentially all ML competitions!!!
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec55">Xgboost on the Cancer Data </h2>
<h2 id="___sec55">Regression Case </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
<div class="highlight" style="background: #eeeedd"><pre style="line-height: 125%"><span></span><span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">matplotlib.pyplot</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">plt</span>
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">numpy</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">np</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.model_selection</span> <span style="color: #8B008B; font-weight: bold">import</span> train_test_split
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">xgboost</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">xgb</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.preprocessing</span> <span style="color: #8B008B; font-weight: bold">import</span> StandardScaler
<span style="color: #8B008B; font-weight: bold">import</span> <span style="color: #008b45; text-decoration: underline">scikitplot</span> <span style="color: #8B008B; font-weight: bold">as</span> <span style="color: #008b45; text-decoration: underline">skplt</span>
<span style="color: #8B008B; font-weight: bold">from</span> <span style="color: #008b45; text-decoration: underline">sklearn.metrics</span> <span style="color: #8B008B; font-weight: bold">import</span> mean_squared_error
n = <span style="color: #B452CD">40</span>
n_boostraps = <span style="color: #B452CD">100</span>
maxdegree = <span style="color: #B452CD">8</span>
<span style="color: #228B22"># Make data set.</span>
x = np.linspace(-<span style="color: #B452CD">3</span>, <span style="color: #B452CD">3</span>, n).reshape(-<span style="color: #B452CD">1</span>, <span style="color: #B452CD">1</span>)
y = np.exp(-x**<span style="color: #B452CD">2</span>) + <span style="color: #B452CD">1.5</span> * np.exp(-(x-<span style="color: #B452CD">2</span>)**<span style="color: #B452CD">2</span>)+ np.random.normal(<span style="color: #B452CD">0</span>, <span style="color: #B452CD">0.1</span>, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
polydegree = np.zeros(maxdegree)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=<span style="color: #B452CD">0.2</span>)
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
<span style="color: #8B008B; font-weight: bold">for</span> degree <span style="color: #8B008B">in</span> <span style="color: #658b00">range</span>(maxdegree):
model = xgb.XGBRegressor(objective =<span style="color: #CD5555">&#39;reg:linear&#39;</span>, colsample_bytree = <span style="color: #B452CD">0.3</span>, learning_rate = <span style="color: #B452CD">0.1</span>,
max_depth = maxdegree, alpha = <span style="color: #B452CD">10</span>, n_estimators = <span style="color: #B452CD">10</span>)
model.fit(X_train_scaled,y_train)
y_pred = model.predict(X_test_scaled)
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**<span style="color: #B452CD">2</span>) )
bias[degree] = np.mean( (y_test - np.mean(y_pred))**<span style="color: #B452CD">2</span> )
variance[degree] = np.mean( np.var(y_pred) )
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Max depth:&#39;</span>, degree)
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Error:&#39;</span>, error[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #8B008B; font-weight: bold">print</span>(<span style="color: #CD5555">&#39;{} &gt;= {} + {} = {}&#39;</span>.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.plot(polydegree, error, label=<span style="color: #CD5555">&#39;Error&#39;</span>)
plt.plot(polydegree, bias, label=<span style="color: #CD5555">&#39;bias&#39;</span>)
plt.plot(polydegree, variance, label=<span style="color: #CD5555">&#39;Variance&#39;</span>)
plt.legend()
plt.show()
</pre></div>
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec56">Xgboost on the Cancer Data </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "perldoc" -->
+139 -31
View File
@@ -126,37 +126,36 @@ div { text-align: justify; text-justify: inter-word; }
'___sec37'),
('Now Bagging', 2, None, '___sec38'),
('Making our own Bagging with Bootstrap', 2, None, '___sec39'),
('Random forests', 2, None, '___sec40'),
('Random Forest Algorithm', 2, None, '___sec41'),
('Changing the Level of the Decision Tree', 2, None, '___sec40'),
('Random forests', 2, None, '___sec41'),
('Random Forest Algorithm', 2, None, '___sec42'),
('Random Forests Compared with other Methods on the Cancer Data',
2,
None,
'___sec42'),
'___sec43'),
('Compare Bagging on Trees with Random Forests',
2,
None,
'___sec43'),
('Bootstrap with Random Forests Instead of a Single Tree',
'___sec44'),
('Bootstrap with Random Forests Instead of a Single Tree, own '
'Bagging',
2,
None,
'___sec44'),
("Boosting, a Bird'e Eye", 2, None, '___sec45'),
'___sec45'),
("Boosting, a Bird'e Eye", 2, None, '___sec46'),
('Adaptive boosting: AdaBoost, Basic Algorithm',
2,
None,
'___sec46'),
('Basic Steps of AdaBoost', 2, None, '___sec47'),
('Figure to Illustrate the Iterative Classification Process',
2,
None,
'___sec48'),
'___sec47'),
('Basic Steps of AdaBoost', 2, None, '___sec48'),
('AdaBoost Examples', 2, None, '___sec49'),
('Gradient boosting: Basics', 2, None, '___sec50'),
('Gradient Boosting, algorithm', 2, None, '___sec51'),
('Gradient Boosting, Examples', 2, None, '___sec52'),
('Gradient Boots with Early Stopping', 2, None, '___sec53'),
('XGBoost: Extreme Gradient Boosting', 2, None, '___sec54'),
('Xgboost on the Cancer Data', 2, None, '___sec55')]}
('Regression Case', 2, None, '___sec55'),
('Xgboost on the Cancer Data', 2, None, '___sec56')]}
end of tocinfo -->
<body>
@@ -1781,7 +1780,66 @@ plt<span style="color: #666666">.</span>show()
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec40">Random forests </h2>
<h2 id="___sec40">Changing the Level of the Decision Tree </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">matplotlib.pyplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">plt</span>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">numpy</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">np</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> train_test_split
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.pipeline</span> <span style="color: #008000; font-weight: bold">import</span> make_pipeline
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.utils</span> <span style="color: #008000; font-weight: bold">import</span> resample
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.tree</span> <span style="color: #008000; font-weight: bold">import</span> DecisionTreeRegressor
n <span style="color: #666666">=</span> <span style="color: #666666">100</span>
n_boostraps <span style="color: #666666">=</span> <span style="color: #666666">100</span>
maxdepth <span style="color: #666666">=</span> <span style="color: #666666">8</span>
<span style="color: #408080; font-style: italic"># Make data set.</span>
x <span style="color: #666666">=</span> np<span style="color: #666666">.</span>linspace(<span style="color: #666666">-3</span>, <span style="color: #666666">3</span>, n)<span style="color: #666666">.</span>reshape(<span style="color: #666666">-1</span>, <span style="color: #666666">1</span>)
y <span style="color: #666666">=</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>x<span style="color: #666666">**2</span>) <span style="color: #666666">+</span> <span style="color: #666666">1.5</span> <span style="color: #666666">*</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>(x<span style="color: #666666">-2</span>)<span style="color: #666666">**2</span>)<span style="color: #666666">+</span> np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>normal(<span style="color: #666666">0</span>, <span style="color: #666666">0.1</span>, x<span style="color: #666666">.</span>shape)
error <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
bias <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
variance <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
polydegree <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdepth)
X_train, X_test, y_train, y_test <span style="color: #666666">=</span> train_test_split(x, y, test_size<span style="color: #666666">=0.2</span>)
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> StandardScaler
scaler <span style="color: #666666">=</span> StandardScaler()
scaler<span style="color: #666666">.</span>fit(X_train)
X_train_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_train)
X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_test)
<span style="color: #008000; font-weight: bold">for</span> degree <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(<span style="color: #666666">1</span>,maxdepth):
model <span style="color: #666666">=</span> DecisionTreeRegressor(max_depth<span style="color: #666666">=</span>degree)
y_pred <span style="color: #666666">=</span> np<span style="color: #666666">.</span>empty((y_test<span style="color: #666666">.</span>shape[<span style="color: #666666">0</span>], n_boostraps))
<span style="color: #008000; font-weight: bold">for</span> i <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(n_boostraps):
x_, y_ <span style="color: #666666">=</span> resample(X_train_scaled, y_train)
model<span style="color: #666666">.</span>fit(x_, y_)
y_pred[:, i] <span style="color: #666666">=</span> model<span style="color: #666666">.</span>predict(X_test_scaled)<span style="color: #408080; font-style: italic">#.ravel()</span>
polydegree[degree] <span style="color: #666666">=</span> degree
error[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>mean((y_test <span style="color: #666666">-</span> y_pred)<span style="color: #666666">**2</span>, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
bias[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( (y_test <span style="color: #666666">-</span> np<span style="color: #666666">.</span>mean(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>))<span style="color: #666666">**2</span> )
variance[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>var(y_pred, axis<span style="color: #666666">=1</span>, keepdims<span style="color: #666666">=</span><span style="color: #008000">True</span>) )
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Polynomial degree:&#39;</span>, degree)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Error:&#39;</span>, error[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;{} &gt;= {} + {} = {}&#39;</span><span style="color: #666666">.</span>format(error[degree], bias[degree], variance[degree], bias[degree]<span style="color: #666666">+</span>variance[degree]))
plt<span style="color: #666666">.</span>xlim(<span style="color: #666666">1</span>,maxdepth)
plt<span style="color: #666666">.</span>plot(polydegree, error, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Error&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, bias, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;bias&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, variance, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Variance&#39;</span>)
plt<span style="color: #666666">.</span>legend()
plt<span style="color: #666666">.</span>show()
</pre></div>
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec41">Random forests </h2>
<p>
Random forests provide an improvement over bagged trees by way of a
@@ -1825,7 +1883,7 @@ this setting.
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec41">Random Forest Algorithm </h2>
<h2 id="___sec42">Random Forest Algorithm </h2>
The algorithm described here can be applied to both classification and regression problems.
<p>
@@ -1851,7 +1909,7 @@ We will grow of forest of say \( M \) trees.
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec42">Random Forests Compared with other Methods on the Cancer Data </h2>
<h2 id="___sec43">Random Forests Compared with other Methods on the Cancer Data </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
@@ -1924,7 +1982,7 @@ plt<span style="color: #666666">.</span>show()
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec43">Compare Bagging on Trees with Random Forests </h2>
<h2 id="___sec44">Compare Bagging on Trees with Random Forests </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
@@ -1946,7 +2004,7 @@ np<span style="color: #666666">.</span>sum(y_pred <span style="color: #666666">=
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec44">Bootstrap with Random Forests Instead of a Single Tree </h2>
<h2 id="___sec45">Bootstrap with Random Forests Instead of a Single Tree, own Bagging </h2>
<p>
@@ -1960,7 +2018,7 @@ np<span style="color: #666666">.</span>sum(y_pred <span style="color: #666666">=
np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>seed(<span style="color: #666666">2018</span>)
n <span style="color: #666666">=</span> <span style="color: #666666">40</span>
n <span style="color: #666666">=</span> <span style="color: #666666">100</span>
n_boostraps <span style="color: #666666">=</span> <span style="color: #666666">100</span>
maxdegree <span style="color: #666666">=</span> <span style="color: #666666">14</span>
@@ -1984,7 +2042,7 @@ X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #6
y_pred <span style="color: #666666">=</span> np<span style="color: #666666">.</span>empty((y_test<span style="color: #666666">.</span>shape[<span style="color: #666666">0</span>], n_boostraps))
<span style="color: #008000; font-weight: bold">for</span> i <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(n_boostraps):
x_, y_ <span style="color: #666666">=</span> resample(X_train_scaled, y_train)
model<span style="color: #666666">.</span>fit(x_, y_)
model<span style="color: #666666">.</span>fit(x_, y_<span style="color: #666666">.</span>ravel())
y_pred[:, i] <span style="color: #666666">=</span> model<span style="color: #666666">.</span>predict(X_test_scaled)<span style="color: #666666">.</span>ravel()
polydegree[degree] <span style="color: #666666">=</span> degree
@@ -2006,7 +2064,7 @@ plt<span style="color: #666666">.</span>show()
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec45">Boosting, a Bird'e Eye </h2>
<h2 id="___sec46">Boosting, a Bird'e Eye </h2>
<p>
The basic idea is to combine weak classifiers in order to create a good
@@ -2023,7 +2081,7 @@ them with a factor.
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec46">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<h2 id="___sec47">Adaptive boosting: AdaBoost, Basic Algorithm </h2>
<p>
The algorithm here is rather straightforward. Assume that our weak
@@ -2045,7 +2103,7 @@ where the function \( I() \) is one if we misclassify and zero if we classify co
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec47">Basic Steps of AdaBoost </h2>
<h2 id="___sec48">Basic Steps of AdaBoost </h2>
<p>
With the above definitions we are now ready to set up the algorithm for AdaBoost.
@@ -2065,7 +2123,7 @@ $$
<li> Then we start looping over all attempts at classifying, namely we start an iterative process for \( m=1:M \), where \( M \) is the final number of classifications. Our given classifier could for example be a plain decision tree.
<ol type="a"></li>
<li> Fit thus a given classifier to the training using the weights \( w_i \).</li>
<li> Fit then a given classifier to the training using the weights \( w_i \).</li>
<li> Compute then \( \mathrm{err} \) and figure out which events are classified properly and which are classified wrongly.</li>
<li> Define a quantity $\alpha_{m} = \log{(1-\mathrm{err})/\mathrm{err}}</li>
<li> Set the new weights to $w_i = w_i\times \exp{(\alpha_m I(y_i\ne G(\boldsymbol{X}_{i*})}.</li>
@@ -2085,11 +2143,6 @@ observations that are missed in the previous iterations.
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec48">Figure to Illustrate the Iterative Classification Process </h2>
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec49">AdaBoost Examples </h2>
<p>
@@ -2349,7 +2402,62 @@ It is now the algorithm which wins essentially all ML competitions!!!
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec55">Xgboost on the Cancer Data </h2>
<h2 id="___sec55">Regression Case </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
<div class="highlight" style="background: #f8f8f8"><pre style="line-height: 125%"><span></span><span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">matplotlib.pyplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">plt</span>
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">numpy</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">np</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.model_selection</span> <span style="color: #008000; font-weight: bold">import</span> train_test_split
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">xgboost</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">xgb</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.preprocessing</span> <span style="color: #008000; font-weight: bold">import</span> StandardScaler
<span style="color: #008000; font-weight: bold">import</span> <span style="color: #0000FF; font-weight: bold">scikitplot</span> <span style="color: #008000; font-weight: bold">as</span> <span style="color: #0000FF; font-weight: bold">skplt</span>
<span style="color: #008000; font-weight: bold">from</span> <span style="color: #0000FF; font-weight: bold">sklearn.metrics</span> <span style="color: #008000; font-weight: bold">import</span> mean_squared_error
n <span style="color: #666666">=</span> <span style="color: #666666">40</span>
n_boostraps <span style="color: #666666">=</span> <span style="color: #666666">100</span>
maxdegree <span style="color: #666666">=</span> <span style="color: #666666">8</span>
<span style="color: #408080; font-style: italic"># Make data set.</span>
x <span style="color: #666666">=</span> np<span style="color: #666666">.</span>linspace(<span style="color: #666666">-3</span>, <span style="color: #666666">3</span>, n)<span style="color: #666666">.</span>reshape(<span style="color: #666666">-1</span>, <span style="color: #666666">1</span>)
y <span style="color: #666666">=</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>x<span style="color: #666666">**2</span>) <span style="color: #666666">+</span> <span style="color: #666666">1.5</span> <span style="color: #666666">*</span> np<span style="color: #666666">.</span>exp(<span style="color: #666666">-</span>(x<span style="color: #666666">-2</span>)<span style="color: #666666">**2</span>)<span style="color: #666666">+</span> np<span style="color: #666666">.</span>random<span style="color: #666666">.</span>normal(<span style="color: #666666">0</span>, <span style="color: #666666">0.1</span>, x<span style="color: #666666">.</span>shape)
error <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
bias <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
variance <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
polydegree <span style="color: #666666">=</span> np<span style="color: #666666">.</span>zeros(maxdegree)
X_train, X_test, y_train, y_test <span style="color: #666666">=</span> train_test_split(x, y, test_size<span style="color: #666666">=0.2</span>)
scaler <span style="color: #666666">=</span> StandardScaler()
scaler<span style="color: #666666">.</span>fit(X_train)
X_train_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_train)
X_test_scaled <span style="color: #666666">=</span> scaler<span style="color: #666666">.</span>transform(X_test)
<span style="color: #008000; font-weight: bold">for</span> degree <span style="color: #AA22FF; font-weight: bold">in</span> <span style="color: #008000">range</span>(maxdegree):
model <span style="color: #666666">=</span> xgb<span style="color: #666666">.</span>XGBRegressor(objective <span style="color: #666666">=</span><span style="color: #BA2121">&#39;reg:linear&#39;</span>, colsample_bytree <span style="color: #666666">=</span> <span style="color: #666666">0.3</span>, learning_rate <span style="color: #666666">=</span> <span style="color: #666666">0.1</span>,
max_depth <span style="color: #666666">=</span> maxdegree, alpha <span style="color: #666666">=</span> <span style="color: #666666">10</span>, n_estimators <span style="color: #666666">=</span> <span style="color: #666666">10</span>)
model<span style="color: #666666">.</span>fit(X_train_scaled,y_train)
y_pred <span style="color: #666666">=</span> model<span style="color: #666666">.</span>predict(X_test_scaled)
polydegree[degree] <span style="color: #666666">=</span> degree
error[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>mean((y_test <span style="color: #666666">-</span> y_pred)<span style="color: #666666">**2</span>) )
bias[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( (y_test <span style="color: #666666">-</span> np<span style="color: #666666">.</span>mean(y_pred))<span style="color: #666666">**2</span> )
variance[degree] <span style="color: #666666">=</span> np<span style="color: #666666">.</span>mean( np<span style="color: #666666">.</span>var(y_pred) )
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Max depth:&#39;</span>, degree)
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Error:&#39;</span>, error[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Bias^2:&#39;</span>, bias[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;Var:&#39;</span>, variance[degree])
<span style="color: #008000; font-weight: bold">print</span>(<span style="color: #BA2121">&#39;{} &gt;= {} + {} = {}&#39;</span><span style="color: #666666">.</span>format(error[degree], bias[degree], variance[degree], bias[degree]<span style="color: #666666">+</span>variance[degree]))
plt<span style="color: #666666">.</span>plot(polydegree, error, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Error&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, bias, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;bias&#39;</span>)
plt<span style="color: #666666">.</span>plot(polydegree, variance, label<span style="color: #666666">=</span><span style="color: #BA2121">&#39;Variance&#39;</span>)
plt<span style="color: #666666">.</span>legend()
plt<span style="color: #666666">.</span>show()
</pre></div>
<p>
<!-- !split --><br><br><br><br><br><br><br><br><br><br>
<h2 id="___sec56">Xgboost on the Cancer Data </h2>
<p>
<!-- code=python (!bc pycod) typeset with pygments style "default" -->
+143 -13
View File
@@ -1796,6 +1796,74 @@
"plt.show()"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Changing the Level of the Decision Tree"
]
},
{
"cell_type": "code",
"execution_count": 25,
"metadata": {
"collapsed": false
},
"outputs": [],
"source": [
"\n",
"import matplotlib.pyplot as plt\n",
"import numpy as np\n",
"from sklearn.model_selection import train_test_split\n",
"from sklearn.pipeline import make_pipeline\n",
"from sklearn.utils import resample\n",
"from sklearn.tree import DecisionTreeRegressor\n",
"\n",
"n = 100\n",
"n_boostraps = 100\n",
"maxdepth = 8\n",
"\n",
"# Make data set.\n",
"x = np.linspace(-3, 3, n).reshape(-1, 1)\n",
"y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)\n",
"error = np.zeros(maxdepth)\n",
"bias = np.zeros(maxdepth)\n",
"variance = np.zeros(maxdepth)\n",
"polydegree = np.zeros(maxdepth)\n",
"X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)\n",
"\n",
"from sklearn.preprocessing import StandardScaler\n",
"scaler = StandardScaler()\n",
"scaler.fit(X_train)\n",
"X_train_scaled = scaler.transform(X_train)\n",
"X_test_scaled = scaler.transform(X_test)\n",
"\n",
"for degree in range(1,maxdepth):\n",
" model = DecisionTreeRegressor(max_depth=degree) \n",
" y_pred = np.empty((y_test.shape[0], n_boostraps))\n",
" for i in range(n_boostraps):\n",
" x_, y_ = resample(X_train_scaled, y_train)\n",
" model.fit(x_, y_)\n",
" y_pred[:, i] = model.predict(X_test_scaled)#.ravel()\n",
"\n",
" polydegree[degree] = degree\n",
" error[degree] = np.mean( np.mean((y_test - y_pred)**2, axis=1, keepdims=True) )\n",
" bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=1, keepdims=True))**2 )\n",
" variance[degree] = np.mean( np.var(y_pred, axis=1, keepdims=True) )\n",
" print('Polynomial degree:', degree)\n",
" print('Error:', error[degree])\n",
" print('Bias^2:', bias[degree])\n",
" print('Var:', variance[degree])\n",
" print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))\n",
"\n",
"plt.xlim(1,maxdepth)\n",
"plt.plot(polydegree, error, label='Error')\n",
"plt.plot(polydegree, bias, label='bias')\n",
"plt.plot(polydegree, variance, label='Variance')\n",
"plt.legend()\n",
"plt.show()"
]
},
{
"cell_type": "markdown",
"metadata": {},
@@ -1872,7 +1940,7 @@
},
{
"cell_type": "code",
"execution_count": 25,
"execution_count": 26,
"metadata": {
"collapsed": false
},
@@ -1954,7 +2022,7 @@
},
{
"cell_type": "code",
"execution_count": 26,
"execution_count": 27,
"metadata": {
"collapsed": false
},
@@ -1967,7 +2035,7 @@
},
{
"cell_type": "code",
"execution_count": 27,
"execution_count": 28,
"metadata": {
"collapsed": false
},
@@ -1986,12 +2054,12 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"## Bootstrap with Random Forests Instead of a Single Tree"
"## Bootstrap with Random Forests Instead of a Single Tree, own Bagging"
]
},
{
"cell_type": "code",
"execution_count": 28,
"execution_count": 29,
"metadata": {
"collapsed": false
},
@@ -2007,7 +2075,7 @@
"\n",
"np.random.seed(2018)\n",
"\n",
"n = 40\n",
"n = 100\n",
"n_boostraps = 100\n",
"maxdegree = 14\n",
"\n",
@@ -2031,7 +2099,7 @@
" y_pred = np.empty((y_test.shape[0], n_boostraps))\n",
" for i in range(n_boostraps):\n",
" x_, y_ = resample(X_train_scaled, y_train)\n",
" model.fit(x_, y_)\n",
" model.fit(x_, y_.ravel())\n",
" y_pred[:, i] = model.predict(X_test_scaled).ravel()\n",
"\n",
" polydegree[degree] = degree\n",
@@ -2120,7 +2188,7 @@
"source": [
"1. Then we start looping over all attempts at classifying, namely we start an iterative process for $m=1:M$, where $M$ is the final number of classifications. Our given classifier could for example be a plain decision tree.\n",
"\n",
"a. Fit thus a given classifier to the training using the weights $w_i$.\n",
"a. Fit then a given classifier to the training using the weights $w_i$.\n",
"\n",
"b. Compute then $\\mathrm{err}$ and figure out which events are classified properly and which are classified wrongly.\n",
"\n",
@@ -2139,7 +2207,6 @@
"new classification step $m$ is then forced to concentrate on those\n",
"observations that are missed in the previous iterations.\n",
"\n",
"## Figure to Illustrate the Iterative Classification Process\n",
"\n",
"\n",
"## AdaBoost Examples\n",
@@ -2149,7 +2216,7 @@
},
{
"cell_type": "code",
"execution_count": 29,
"execution_count": 30,
"metadata": {
"collapsed": false
},
@@ -2239,7 +2306,7 @@
},
{
"cell_type": "code",
"execution_count": 30,
"execution_count": 31,
"metadata": {
"collapsed": false
},
@@ -2338,7 +2405,7 @@
},
{
"cell_type": "code",
"execution_count": 31,
"execution_count": 32,
"metadata": {
"collapsed": false
},
@@ -2423,12 +2490,75 @@
"\n",
"It is now the algorithm which wins essentially all ML competitions!!!\n",
"\n",
"## Regression Case"
]
},
{
"cell_type": "code",
"execution_count": 33,
"metadata": {
"collapsed": false
},
"outputs": [],
"source": [
"import matplotlib.pyplot as plt\n",
"import numpy as np\n",
"from sklearn.model_selection import train_test_split\n",
"import xgboost as xgb\n",
"from sklearn.preprocessing import StandardScaler\n",
"import scikitplot as skplt\n",
"from sklearn.metrics import mean_squared_error\n",
"\n",
"n = 40\n",
"n_boostraps = 100\n",
"maxdegree = 8\n",
"\n",
"# Make data set.\n",
"x = np.linspace(-3, 3, n).reshape(-1, 1)\n",
"y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)\n",
"\n",
"error = np.zeros(maxdegree)\n",
"bias = np.zeros(maxdegree)\n",
"variance = np.zeros(maxdegree)\n",
"polydegree = np.zeros(maxdegree)\n",
"X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)\n",
"scaler = StandardScaler()\n",
"scaler.fit(X_train)\n",
"X_train_scaled = scaler.transform(X_train)\n",
"X_test_scaled = scaler.transform(X_test)\n",
"\n",
"for degree in range(maxdegree):\n",
" model = xgb.XGBRegressor(objective ='reg:linear', colsample_bytree = 0.3, learning_rate = 0.1,\n",
" max_depth = maxdegree, alpha = 10, n_estimators = 10)\n",
" model.fit(X_train_scaled,y_train)\n",
" y_pred = model.predict(X_test_scaled)\n",
" polydegree[degree] = degree\n",
" error[degree] = np.mean( np.mean((y_test - y_pred)**2) )\n",
" bias[degree] = np.mean( (y_test - np.mean(y_pred))**2 )\n",
" variance[degree] = np.mean( np.var(y_pred) )\n",
" print('Max depth:', degree)\n",
" print('Error:', error[degree])\n",
" print('Bias^2:', bias[degree])\n",
" print('Var:', variance[degree])\n",
" print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))\n",
"\n",
"plt.plot(polydegree, error, label='Error')\n",
"plt.plot(polydegree, bias, label='bias')\n",
"plt.plot(polydegree, variance, label='Variance')\n",
"plt.legend()\n",
"plt.show()"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Xgboost on the Cancer Data"
]
},
{
"cell_type": "code",
"execution_count": 32,
"execution_count": 34,
"metadata": {
"collapsed": false
},
Binary file not shown.
+123 -6
View File
@@ -1449,6 +1449,69 @@ plt.show()
!ec
!split
===== Changing the Level of the Decision Tree =====
!bc pycod
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn.pipeline import make_pipeline
from sklearn.utils import resample
from sklearn.tree import DecisionTreeRegressor
n = 100
n_boostraps = 100
maxdepth = 8
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdepth)
bias = np.zeros(maxdepth)
variance = np.zeros(maxdepth)
polydegree = np.zeros(maxdepth)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
from sklearn.preprocessing import StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(1,maxdepth):
model = DecisionTreeRegressor(max_depth=degree)
y_pred = np.empty((y_test.shape[0], n_boostraps))
for i in range(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled)#.ravel()
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2, axis=1, keepdims=True) )
bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=1, keepdims=True))**2 )
variance[degree] = np.mean( np.var(y_pred, axis=1, keepdims=True) )
print('Polynomial degree:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.xlim(1,maxdepth)
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()
!ec
!split
===== Random forests =====
@@ -1599,7 +1662,7 @@ np.sum(y_pred == y_pred_rf) / len(y_pred)
!split
===== Bootstrap with Random Forests Instead of a Single Tree =====
===== Bootstrap with Random Forests Instead of a Single Tree, own Bagging =====
!bc pycod
@@ -1612,7 +1675,7 @@ from sklearn.ensemble import RandomForestRegressor
np.random.seed(2018)
n = 40
n = 100
n_boostraps = 100
maxdegree = 14
@@ -1636,7 +1699,7 @@ for degree in range(maxdegree):
y_pred = np.empty((y_test.shape[0], n_boostraps))
for i in range(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
model.fit(x_, y_.ravel())
y_pred[:, i] = model.predict(X_test_scaled).ravel()
polydegree[degree] = degree
@@ -1707,7 +1770,7 @@ o We rewrite the misclassification error as
\]
!et
o Then we start looping over all attempts at classifying, namely we start an iterative process for $m=1:M$, where $M$ is the final number of classifications. Our given classifier could for example be a plain decision tree.
o Fit thus a given classifier to the training using the weights $w_i$.
o Fit then a given classifier to the training using the weights $w_i$.
o Compute then $\mathrm{err}$ and figure out which events are classified properly and which are classified wrongly.
o Define a quantity $\alpha_{m} = \log{(1-\mathrm{err})/\mathrm{err}}
o Set the new weights to $w_i = w_i\times \exp{(\alpha_m I(y_i\ne G(\bm{X}_{i*})}.
@@ -1721,8 +1784,6 @@ difficult to classifiy correctly are given a larger influence. Each
new classification step $m$ is then forced to concentrate on those
observations that are missed in the previous iterations.
!split
===== Figure to Illustrate the Iterative Classification Process =====
!split
@@ -1965,6 +2026,62 @@ sketch for efficient proposal calculation. It introduces a novel sparsity-aware
It is now the algorithm which wins essentially all ML competitions!!!
!split
===== Regression Case =====
!bc pycod
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
import xgboost as xgb
from sklearn.preprocessing import StandardScaler
import scikitplot as skplt
from sklearn.metrics import mean_squared_error
n = 40
n_boostraps = 100
maxdegree = 8
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
polydegree = np.zeros(maxdegree)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(maxdegree):
model = xgb.XGBRegressor(objective ='reg:linear', colsample_bytree = 0.3, learning_rate = 0.1,
max_depth = maxdegree, alpha = 10, n_estimators = 10)
model.fit(X_train_scaled,y_train)
y_pred = model.predict(X_test_scaled)
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2) )
bias[degree] = np.mean( (y_test - np.mean(y_pred))**2 )
variance[degree] = np.mean( np.var(y_pred) )
print('Max depth:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()
!ec
!split
===== Xgboost on the Cancer Data =====
!bc pycod
@@ -0,0 +1,56 @@
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn.pipeline import make_pipeline
from sklearn.utils import resample
from sklearn.tree import DecisionTreeRegressor
np.random.seed(2018)
n = 40
n_boostraps = 100
maxdegree = 14
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
polydegree = np.zeros(maxdegree)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
from sklearn.preprocessing import StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(maxdegree):
model = DecisionTreeRegressor(max_depth=2)
y_pred = np.empty((y_test.shape[0], n_boostraps))
for i in range(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled).ravel()
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2, axis=1, keepdims=True) )
bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=1, keepdims=True))**2 )
variance[degree] = np.mean( np.var(y_pred, axis=1, keepdims=True) )
print('Polynomial degree:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()
@@ -0,0 +1,54 @@
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn.pipeline import make_pipeline
from sklearn.utils import resample
from sklearn.tree import DecisionTreeRegressor
n = 100
n_boostraps = 100
maxdepth = 8
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdepth)
bias = np.zeros(maxdepth)
variance = np.zeros(maxdepth)
polydegree = np.zeros(maxdepth)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
from sklearn.preprocessing import StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(1,maxdepth):
model = DecisionTreeRegressor(max_depth=degree)
y_pred = np.empty((y_test.shape[0], n_boostraps))
for i in range(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled)#.ravel()
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2, axis=1, keepdims=True) )
bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=1, keepdims=True))**2 )
variance[degree] = np.mean( np.var(y_pred, axis=1, keepdims=True) )
print('Polynomial degree:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.xlim(1,maxdepth)
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()
@@ -0,0 +1,54 @@
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn.pipeline import make_pipeline
from sklearn.utils import resample
from sklearn.tree import DecisionTreeRegressor
n = 100
n_boostraps = 100
maxdepth = 8
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdepth)
bias = np.zeros(maxdepth)
variance = np.zeros(maxdepth)
polydegree = np.zeros(maxdepth)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
from sklearn.preprocessing import StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(1,maxdepth):
model = DecisionTreeRegressor(max_depth=degree)
y_pred = np.empty((y_test.shape[0], n_boostraps))
for i in range(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled)#.ravel()
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2, axis=1, keepdims=True) )
bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=1, keepdims=True))**2 )
variance[degree] = np.mean( np.var(y_pred, axis=1, keepdims=True) )
print('Polynomial degree:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.xlim(1,maxdegree)
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()
@@ -8,13 +8,14 @@ from sklearn.ensemble import RandomForestRegressor
np.random.seed(2018)
n = 40
n = 500
n_boostraps = 100
maxdegree = 14
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
@@ -32,8 +33,8 @@ for degree in range(maxdegree):
y_pred = np.empty((y_test.shape[0], n_boostraps))
for i in range(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train)
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled)#.ravel()
model.fit(x_, y_.ravel())
y_pred[:, i] = model.predict(X_test_scaled)
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2, axis=1, keepdims=True) )
@@ -0,0 +1,54 @@
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn.pipeline import make_pipeline
from sklearn.utils import resample
from sklearn.ensemble import RandomForestRegressor
np.random.seed(2018)
n = 40
n_boostraps = 100
maxdegree = 14
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
polydegree = np.zeros(maxdegree)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
from sklearn.preprocessing import StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(maxdegree):
model = RandomForestRegressor()
y_pred = np.empty((y_test.shape[0], n_boostraps))
for i in range(n_boostraps):
x_, y_ = resample(X_train_scaled, y_train).ravel()
model.fit(x_, y_)
y_pred[:, i] = model.predict(X_test_scaled).ravel()
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2, axis=1, keepdims=True) )
bias[degree] = np.mean( (y_test - np.mean(y_pred, axis=1, keepdims=True))**2 )
variance[degree] = np.mean( np.var(y_pred, axis=1, keepdims=True) )
print('Polynomial degree:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()
@@ -29,8 +29,6 @@ accuracy = cross_validate(Random_Forest_model,X_test_scaled,y_test,cv=10)['test_
print(accuracy)
print("Test set accuracy with Random Forests and scaled data: {:.2f}".format(Random_Forest_model.score(X_test_scaled,y_test)))
y_pred = Random_Forest_model.predict(X_test_scaled)
skplt.metrics.plot_confusion_matrix(y_test, y_pred, normalize=True)
plt.show()
@@ -0,0 +1,41 @@
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn.datasets import load_breast_cancer
from sklearn.tree import DecisionTreeClassifier
from sklearn.ensemble import RandomForestClassifier
from sklearn.preprocessing import LabelEncoder
from sklearn.model_selection import cross_validate
import scikitplot as skplt
# Load the data
cancer = load_breast_cancer()
X_train, X_test, y_train, y_test = train_test_split(cancer.data,cancer.target,random_state=0)
print(X_train.shape)
print(X_test.shape)
#now scale the data
from sklearn.preprocessing import StandardScaler
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
# Data set not specificied
#Instantiate the model with 100 trees and entropy as splitting criteria
Random_Forest_model = RandomForestClassifier(n_estimators=500,criterion="entropy")
Random_Forest_model.fit(X_train_scaled, y_train)
#Cross validation
accuracy = cross_validate(Random_Forest_model,X_test_scaled,y_test,cv=10)['test_score']
print(accuracy)
print("Test set accuracy with Random Forests and scaled data: {:.2f}".format(Random_Forest_model.score(X_test_scaled,y_test)))
y_pred = Random_Forest_model.predict(X_test_scaled)
skplt.metrics.plot_confusion_matrix(y_test, y_pred, normalize=True)
plt.show()
y_probas = Random_Forest_model.predict_proba(X_test_scaled)
skplt.metrics.plot_roc(y_test, y_probas)
plt.show()
skplt.metrics.plot_cumulative_gain(y_test, y_probas)
plt.show()
@@ -0,0 +1,47 @@
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
import xgboost as xgb
from sklearn.preprocessing import StandardScaler
import scikitplot as skplt
from sklearn.metrics import mean_squared_error
n = 40
n_boostraps = 100
maxdegree = 8
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
polydegree = np.zeros(maxdegree)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(maxdegree):
model = xgb.XGBRegressor(objective ='reg:linear', colsample_bytree = 0.3, learning_rate = 0.1,
max_depth = maxdegree, alpha = 10, n_estimators = 10)
model.fit(X_train_scaled,y_train)
y_pred = model.predict(X_test_scaled)
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2) )
bias[degree] = np.mean( (y_test - np.mean(y_pred))**2 )
variance[degree] = np.mean( np.var(y_pred) )
print('Polynomial degree:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()
@@ -0,0 +1,47 @@
import matplotlib.pyplot as plt
import numpy as np
from sklearn.model_selection import train_test_split
import xgboost as xgb
from sklearn.preprocessing import StandardScaler
import scikitplot as skplt
from sklearn.metrics import mean_squared_error
n = 500
n_boostraps = 100
maxdegree = 8
# Make data set.
x = np.linspace(-3, 3, n).reshape(-1, 1)
y = np.exp(-x**2) + 1.5 * np.exp(-(x-2)**2)+ np.random.normal(0, 0.1, x.shape)
error = np.zeros(maxdegree)
bias = np.zeros(maxdegree)
variance = np.zeros(maxdegree)
polydegree = np.zeros(maxdegree)
X_train, X_test, y_train, y_test = train_test_split(x, y, test_size=0.2)
scaler = StandardScaler()
scaler.fit(X_train)
X_train_scaled = scaler.transform(X_train)
X_test_scaled = scaler.transform(X_test)
for degree in range(maxdegree):
model = xgb.XGBRegressor(objective ='reg:linear', colsample_bytree = 0.3, learning_rate = 0.1,
max_depth = maxdegree, alpha = 10, n_estimators = 10)
model.fit(X_train_scaled,y_train)
y_pred = model.predict(X_test_scaled)
polydegree[degree] = degree
error[degree] = np.mean( np.mean((y_test - y_pred)**2) )
bias[degree] = np.mean( (y_test - np.mean(y_pred))**2 )
variance[degree] = np.mean( np.var(y_pred) )
print('Polynomial degree:', degree)
print('Error:', error[degree])
print('Bias^2:', bias[degree])
print('Var:', variance[degree])
print('{} >= {} + {} = {}'.format(error[degree], bias[degree], variance[degree], bias[degree]+variance[degree]))
plt.plot(polydegree, error, label='Error')
plt.plot(polydegree, bias, label='bias')
plt.plot(polydegree, variance, label='Variance')
plt.legend()
plt.show()