Skip to content

Commit

Permalink
Deploy commit: harmonize with upstream 560b8c3
Browse files Browse the repository at this point in the history
  • Loading branch information
jannes-m committed Sep 25, 2024
1 parent ce06a85 commit 557fd28
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 6 deletions.
4 changes: 3 additions & 1 deletion 12-spatial-cv.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,12 @@ library(lgr) # logging framework for R
library(mlr3) # unified interface to machine learning algorithms
library(mlr3learners) # most important machine learning algorithms
library(mlr3extralearners) # access to even more learning algorithms
library(mlr3spatiotempcv) # spatiotemporal resampling strategies
library(mlr3proba) # make probabilistic predictions, here only needed for mlr3extralearners::list_learners()
library(mlr3spatiotempcv) # spatio-temporal resampling strategies
library(mlr3tuning) # hyperparameter tuning
library(mlr3viz) # plotting functions for mlr3 objects
library(progressr) # report progress updates
library(pROC) # compute roc values
```

Required data will be attached in due course.
Expand Down
Binary file modified figures/circle-intersection-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified figures/points-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion search.json

Large diffs are not rendered by default.

10 changes: 6 additions & 4 deletions spatial-cv.html
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,12 @@ <h2>Prerequisites<a class="anchor" aria-label="anchor" href="#prerequisites-10">
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://mlr3.mlr-org.com">mlr3</a></span><span class="op">)</span> <span class="co"># unified interface to machine learning algorithms</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://mlr3learners.mlr-org.com">mlr3learners</a></span><span class="op">)</span> <span class="co"># most important machine learning algorithms</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va">mlr3extralearners</span><span class="op">)</span> <span class="co"># access to even more learning algorithms</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://mlr3spatiotempcv.mlr-org.com/">mlr3spatiotempcv</a></span><span class="op">)</span> <span class="co"># spatiotemporal resampling strategies</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://mlr3proba.mlr-org.com">mlr3proba</a></span><span class="op">)</span> <span class="co"># make probabilistic predictions, here only needed for mlr3extralearners::list_learners()</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://mlr3spatiotempcv.mlr-org.com/">mlr3spatiotempcv</a></span><span class="op">)</span> <span class="co"># spatio-temporal resampling strategies</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://mlr3tuning.mlr-org.com">mlr3tuning</a></span><span class="op">)</span> <span class="co"># hyperparameter tuning</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://mlr3viz.mlr-org.com">mlr3viz</a></span><span class="op">)</span> <span class="co"># plotting functions for mlr3 objects</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://progressr.futureverse.org">progressr</a></span><span class="op">)</span> <span class="co"># report progress updates</span></span></code></pre></div>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://progressr.futureverse.org">progressr</a></span><span class="op">)</span> <span class="co"># report progress updates</span></span>
<span><span class="kw"><a href="https://rdrr.io/r/base/library.html">library</a></span><span class="op">(</span><span class="va"><a href="https://xrobin.github.io/pROC/">pROC</a></span><span class="op">)</span> <span class="co"># compute roc values</span></span></code></pre></div>
<p>Required data will be attached in due course.</p>
</div>
<div id="intro-cv1" class="section level2" number="12.1">
Expand Down Expand Up @@ -395,8 +397,8 @@ <h2>
One of the most popular measures to assess the predictive performance of a binomial model is the Area Under the Receiver Operator Characteristic Curve (AUROC).
This is a value between 0.5 and 1.0, with 0.5 indicating a model that is no better than random and 1.0 indicating perfect prediction of the two classes.
Thus, the higher the AUROC, the better the model’s predictive power.
The following code chunk computes the AUROC value of the model with <code>roc()</code>, which takes the response and the predicted values as inputs.
<code>auc()</code> returns the area under the curve.</p>
The following code chunk computes the AUROC value of the model with <code><a href="https://rdrr.io/pkg/pROC/man/roc.html">roc()</a></code>, which takes the response and the predicted values as inputs.
<code><a href="https://rdrr.io/pkg/pROC/man/auc.html">auc()</a></code> returns the area under the curve.</p>
<div class="sourceCode" id="cb421"><pre class="downlit sourceCode r">
<code class="sourceCode R"><span><span class="fu">pROC</span><span class="fu">::</span><span class="fu"><a href="https://rdrr.io/pkg/pROC/man/auc.html">auc</a></span><span class="op">(</span><span class="fu">pROC</span><span class="fu">::</span><span class="fu"><a href="https://rdrr.io/pkg/pROC/man/roc.html">roc</a></span><span class="op">(</span><span class="va">lsl</span><span class="op">$</span><span class="va">lslpts</span>, <span class="fu"><a href="https://rdrr.io/r/stats/fitted.values.html">fitted</a></span><span class="op">(</span><span class="va">fit</span><span class="op">)</span><span class="op">)</span><span class="op">)</span></span>
<span><span class="co">#&gt; Area under the curve: 0.8216</span></span></code></pre></div>
Expand Down

0 comments on commit 557fd28

Please sign in to comment.