This commit is contained in:
Morten Hjorth-Jensen
2024-11-17 15:55:37 +01:00
parent df2f85227b
commit 3147098147
191 changed files with 20795 additions and 4445 deletions
+13 -10
View File
@@ -34,7 +34,7 @@
<link rel="stylesheet" type="text/css" href="_static/styles/sphinx-book-theme.css?v=a3416100" />
<link rel="stylesheet" type="text/css" href="_static/togglebutton.css?v=13237357" />
<link rel="stylesheet" type="text/css" href="_static/copybutton.css?v=76b2166b" />
<link rel="stylesheet" type="text/css" href="_static/mystnb.4510f1fc1dee50b3e5859aac5469c37c29e427902b24a333a5f9fcb2f0b3ac41.css" />
<link rel="stylesheet" type="text/css" href="_static/mystnb.4510f1fc1dee50b3e5859aac5469c37c29e427902b24a333a5f9fcb2f0b3ac41.css?v=be8a1c11" />
<link rel="stylesheet" type="text/css" href="_static/sphinx-thebe.css?v=4fa983c6" />
<link rel="stylesheet" type="text/css" href="_static/sphinx-design.min.css?v=95c83b7e" />
@@ -254,6 +254,9 @@
<li class="toctree-l1"><a class="reference internal" href="week44.html">Week 44, Convolutional Neural Networks (CNN)</a></li>
<li class="toctree-l1"><a class="reference internal" href="week45.html">Week 45, Convolutional Neural Networks (CCNs) and Recurrent Neural Networks (RNNs)</a></li>
<li class="toctree-l1"><a class="reference internal" href="week46.html">Week 46: Decision Trees, Ensemble methods and Random Forests</a></li>
<li class="toctree-l1"><a class="reference internal" href="week47.html">Week 47: From Decision Trees to Ensemble Methods, Random Forests and Boosting Methods</a></li>
<li class="toctree-l1"><a class="reference internal" href="exercisesweek47.html">Exercise week 47</a></li>
</ul>
<p aria-level="2" class="caption" role="heading"><span class="caption-text">Projects</span></p>
<ul class="nav bd-sidenav">
@@ -727,7 +730,7 @@ Thereafter we wish to apply it to data which were not included in the training.
</div>
</div>
<div class="cell_output docutils container">
<img alt="_images/ac78b4c9fff962e3b699429550b7c321effb3032e3444a63d30a8efd19ebb5d6.png" src="_images/ac78b4c9fff962e3b699429550b7c321effb3032e3444a63d30a8efd19ebb5d6.png" />
<img alt="_images/7208bf883e220945a23bf4a64d7c474c22032a9479d0230f3f7627fde6c870e3.png" src="_images/7208bf883e220945a23bf4a64d7c474c22032a9479d0230f3f7627fde6c870e3.png" />
</div>
</div>
<p>This example serves several aims. It allows us to demonstrate several
@@ -812,7 +815,7 @@ to be dominated by outliers.</p>
</div>
</div>
<div class="cell_output docutils container">
<img alt="_images/1ce5de7d3b7bb6c52facf4e858e6c4b7eb6a4371cc0e4454c2f6e913d60da064.png" src="_images/1ce5de7d3b7bb6c52facf4e858e6c4b7eb6a4371cc0e4454c2f6e913d60da064.png" />
<img alt="_images/daf635918e102d6af1572d0f6fcb2bcd9c93425cd41e91dc85022a813e3b1da5.png" src="_images/daf635918e102d6af1572d0f6fcb2bcd9c93425cd41e91dc85022a813e3b1da5.png" />
</div>
</div>
<p>Depending on the parameter in front of the normal distribution, we may
@@ -859,16 +862,16 @@ example of the functionality of <strong>Scikit-Learn</strong>.</p>
</div>
<div class="cell_output docutils container">
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>The intercept alpha:
[2.04161185]
[1.97386121]
Coefficient beta :
[[4.82942403]]
Mean squared error: 0.25
Variance score: 0.87
[[5.12574106]]
Mean squared error: 0.20
Variance score: 0.92
Mean squared log error: 0.01
Mean absolute error: 0.40
Mean absolute error: 0.36
</pre></div>
</div>
<img alt="_images/544b198f663ddf96819b62f0d11bd4bb1b0916b7f81b07edba1299dabca63229.png" src="_images/544b198f663ddf96819b62f0d11bd4bb1b0916b7f81b07edba1299dabca63229.png" />
<img alt="_images/1168b639886622ca16f51897f200d03b2de325bfc3f6688b4b75ff4473160f59.png" src="_images/1168b639886622ca16f51897f200d03b2de325bfc3f6688b4b75ff4473160f59.png" />
</div>
</div>
<p>The function <strong>coef</strong> gives us the parameter <span class="math notranslate nohighlight">\(\beta\)</span> of our fit while <strong>intercept</strong> yields
@@ -964,7 +967,7 @@ a linear <span class="math notranslate nohighlight">\(x\)</span>-dependence we s
</div>
</div>
<div class="cell_output docutils container">
<img alt="_images/5b8216a39dc2cc82a708564495577a73182745d197edb3712c33ea439726bbd7.png" src="_images/5b8216a39dc2cc82a708564495577a73182745d197edb3712c33ea439726bbd7.png" />
<img alt="_images/2e42f972e6bd064ce2062209501a6f469d0ebd090cf62a0159f888f2deaa3de7.png" src="_images/2e42f972e6bd064ce2062209501a6f469d0ebd090cf62a0159f888f2deaa3de7.png" />
<div class="output stream highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>0.004999999999999993
</pre></div>
</div>