https://debruine.github.io/talks/teach-repro-2025/
In this talk, I will give an overview of how the School of Psychology and Neuroscience transformed our undergraduate and postgraduate curriculum to prioritise data skills and reproducibility using open source software and teaching resources. While our ethos is agnostic to specific tools and coding languages, I will give specific examples of how we use R, RStudio, and RMarkdown/quarto to instill transferable skills and good research practice supporting computational reproducibility and literate coding.
“We value the quality of our research over its quantity”
“How research is done is as important as what is done”
Ideally, give open materials a permanent reference, like a DOI.
via the Turing Way

An analysis by Nuijten et al. (2016) of over 250K p-values reported in 8 major psych journals from 1985 to 2013 found that:
Of 35 articles published in Cognition with usable data (but no code, Hardwicke et al. (2018) found:
Of 62 Registered Reports in psychology published from 2014–2018, 36 had data and analysis code, 31 could be run, and 21 reproduced all the main results (Obels et al, 2020)
An approach to programming that focuses on the creation of a document containing a mix of human-readable narrative text and machine-readable computer code.



Now I can make:
verbatim codeYou can run and/or display code and/or its output.
Create figures in markdown or code and reference by their label (e.g., @fig-penguins) to automatically number and link in text (Figure 1).
Figure 1: Penguin bill length by body mass
Create tables in markdown or code in link like figures (e.g., @tbl-mean for Table 1).
```{r}
#| label: tbl-mean
#| tbl-cap: Mean body measurements by species.
summarise(penguins,
across(bill_len:body_mass, \(x) mean(x, na.rm = TRUE)),
.by = species) |>
mutate(across(-species, \(x) signif(x, 3)))
```| species | bill_len | bill_dep | flipper_len | body_mass |
|---|---|---|---|---|
| Adelie | 38.8 | 18.3 | 190 | 3700 |
| Gentoo | 47.5 | 15.0 | 217 | 5080 |
| Chinstrap | 48.8 | 18.4 | 196 | 3730 |
See the quarto guide for more diagramming tools.
Add # <1> after lines of code and a list of annotations after the code block. Set code-annotations in the YAML header to below (default), hover or select (better for touchscreens).
```{r}
penguin_measures <- penguins |>
mutate(
bill_ratio = bill_dep / bill_len,
bill_area = bill_dep * bill_len
)
```penguin_measures from penguins, and then,
mutate() function to add new columns.
bill_ratio and bill_area), and set them equal to functions of the existing columns bill_dep and bill_len
mutate() function.
You can create any pandoc format with quarto (see the full list).
My favourites are reports, websites, books, and presentations (this talk was written in quarto!).
The process of methodically and systematically checking over code–your own or someone else’s–after it has been written.
Promoting reproducibility and open science requires not only teaching relevant values and practices, but also providing the skills needed for reproducible data analysis. Improving students’ data skills will also enhance their employability within and beyond the academic context.
McAleer, P., Stack, N., Woods, H., DeBruine, L. M., Paterson, H. M., Nordmann, E., … Barr, D. J. (2022). Embedding Data Skills in Research Methods Education: Preparing Students for Reproducible Research. https://doi.org/10.31234/osf.io/hq68s
Teaching Reproducible Research
https://debruine.github.io/talks/teach-repro-2025/
Lisa DeBruine
