-
Notifications
You must be signed in to change notification settings - Fork 14
/
week 4.qmd
93 lines (55 loc) · 5.12 KB
/
week 4.qmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# Reproducible Research {#sec-wk4}
**Setting up simulation studies that everyone can replicate and reproduce**
::: callout-tip
## Lecture 4
This week's slides can be found [here](slides/lec-4.html)
:::
---
## Introduction
Dear all,
This week, it's all coming together: you will apply your newly acquired markup language skills and build a reproducible research archive from scratch. We will assume that, by now, you're familiar with Git and GitHub. If that's not the case, please refer to last weeks' course materials.
The contents of the research compendium will consist of the simulation study performed by [Boulesteix, Groenwold, Abrahamowicz, et al. (2020)](https://doi.org/10.1136/bmjopen-2020-039921). In this week's exercises, you will make the simulation study easier to reproduce. By the end of the exercises you've created an improved version of how this simulation may be represented in the online supplement.
All the best,
Hanne and Gerko
---
## Preparation
### Required reading
Read [Boulesteix, Groenwold, Abrahamowicz, et al. (2020)](https://doi.org/10.1136/bmjopen-2020-039921).
Most of the paper may be skimmed through, but make sure to closely read the penultimate section named "An example of a statistical simulation", since this will be this week's case study.
### Optional reading
The interested reader may also consider reading the original [Morris, White, & Crowther (2019)](https://doi.org/10.1002/sim.8086) paper, that Boulesteix et al. (2020) is based on. This shouldn't be too hard, because the target audience of 'Using simulation studies to evaluate statistical methods' overlaps significantly with graduate students in statistics. And moreover, you might find it extremely useful for your Master's thesis!
<!-- <iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/EbAAmrB0luA?si=i9kFFtDJ7T_XlGI3" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe> -->
<!-- ## Browse the `Quarto` website -->
<!-- The people at `Posit` have designed [this awesome companion website](https://quarto.org/docs/guide/) that details pretty much everything `Quarto`. Have a look around and remember this source when you're in need of some additional functionality. Much of what you can do with `Quarto` is detailed here. -->
---
## Exercise 1
In this exercise you will follow the Utrecht University tutorial on creating reproducible manuscripts: [https://utrechtuniversity.github.io/workshop-reproducible-manuscripts/introduction.html](https://utrechtuniversity.github.io/workshop-reproducible-manuscripts/introduction.html). The link intentionally refers to the section named 'Introduction'; previous sections are not relevant for you.
Follow the instructions in the sections 'Introduction', 'Getting Started', 'Writing', and 'Code'.
In the section 'Rendering', you may skip the instructions for creating `docx` documents, using the terminal, and managing multiple file outputs. We will only need the `pdf` output.
### Hint
After this exercise, the YAML header for your Quarto document might look something like the code in the footnote[^1].
[^1]:
```
---
title: "My Reproducible Manuscript"
format:
pdf: default
bibliography: references.bib
---
```
<!-- The contents of the compendium will consist of the simulation study performed by Boulesteix et al. (2020), see the next exercise for more information. -->
<!-- Bring this presentation to the next class -->
---
## Exercise 2
In this exercise, you will substitute the contents of the research compendium you've just created with Boulesteix et al.'s simulation study.
The original simulation script was supplemented as a `pdf` file. Lucky for you, we've already copied all of the `R` code from their `pdf` supplement for you. The resulting `R` script is available from [https://github.com/gerkovink/markup/blob/main/documents/week-4/original_script.R](https://github.com/gerkovink/markup/blob/main/documents/week-4/original_script.R).
Likewise, we've retrieved the necessary data for you. The complete database can be accessed through [https://wwwn.cdc.gov/nchs/nhanes/continuousnhanes/default.aspx?Begi-nYear=2015](https://wwwn.cdc.gov/nchs/nhanes/continuousnhanes/default.aspx?Begi-nYear=2015), whereas the relevant data files for this exercise can be downloaded directly from [https://github.com/gerkovink/markup/blob/main/documents/week-4/raw_data](https://github.com/gerkovink/markup/blob/main/documents/week-4/raw_data).
Now it's up to you! Create a reproducible document that contains the simulation study and results. Make sure that this document is part of a fully reproducible research compendium.
Submit the research compendium to this year's Markup Languages repository with a pull request on GitHub.
### Hint
Exchange research compendiums with a classmate to make sure that your work is indeed completely reproducible.
<!-- The document should include the following statistics: -->
<!-- - absolute bias -->
<!-- - standard error -->
<!-- - lower bound of the 95% confidence interval -->
<!-- - upper bound of the 95% confidence interval -->