Quarto for Data Science Slides (and beyond)

UC Love Data Week 2025

Similar feel, different format

  • just another Quarto doc
  • …but with format: revealjs in the YAML
---
title: "Quarto for Data Science Slides (and beyond)"
subtitle: "UC Love Data Week 2025"
format: revealjs
---

Create a new slide with ##

## My first slide title

Here's some slide content

## My second slide title {#updated-slug data-menu-title="Updated nav menu title"}
 
Slide two content here!


Slide titles become your URL slug (unique portion of URL) and navigation menu title (see hamburger, bottom left!) – but you can modify these!

Create incremental lists

  • make list items
  • appear one by one
  • by surrounding your list with a div (:::content:::)
  • and applying the .incremental class
::: {.incremental}
- make list items
- appear one by one
- by surrounding your list with a div (`:::`content`:::`)
- and applying the `.incremental` class
:::

Incrementally reveal anything

By placing . . . between any content


This content appears after a click!

## Incrementally reveal anything

By placing `. . .` between any content

<br>

. . . 

This content appears after a click!

. . .

Embed code + output

library(tidyverse)

freckles <- tribble(
  ~id, ~num_freckles,
  "Cat 1", 9, 
  "Cat 2", 4
)

ggplot(data = freckles, aes(x = num_freckles, y = fct_rev(id))) + 
  geom_col() +
  labs(title = "Number of freckles on my cats' noses", x = "# of freckles") +
  scale_x_continuous(breaks = scales::breaks_width(2)) +
  theme(axis.title.y = element_blank())

Code chunk options above:

#| eval: true
#| echo: true
#| output-location: column
#| code-line-numbers: "|1|3-7|11,13"

Or just the output

::: {.notes}
Also, you can include speaker notes! Press "S" to activate.
:::

Apply styles using Sass & CSS

Update the appearance of your slides by linking a stylesheet in your YAML:

---
title: "Quarto for Data Science Slides (and beyond)"
subtitle: "UC Love Data Week 2025"
format: 
  revealjs:
    theme: my-styles.scss
---

Import Google Fonts, define Sass variables, write CSS.

Thanks for watching & happy slide-making!