Requirements

Requirements

  • You must have installed quarto: https://quarto.org/docs/get-started/
  • Download the dataframe_fishi.csv
  • Have the necessary packages been installed?
# fishi
devtools::install_github("https://github.com/OB7-IRD/fishi", INSTALL_opts=c("--no-multiarch"))

# other packages
pkg_list <- c(
  "quarto", "rmarkdown", "kableExtra", "ggplot2", "dplyr"
  )
install.packages(pkg_list, repos="http://cran.us.r-project.org")

Great, let’s get started!

The basics

The basics

Composition of a Quarto script :

  • IDE Studio

  • YAML header

  • Anatomy of a document

    • Titles
    • The syntax
    • Adding an image
    • Creating two columns

The basics - IDE Studio

1. Create a quarto file

1.  File > New File > Quarto document

2.  Details : Titre / Auteur / HTML

3.  Create

The basics - IDE Studio

1. Create a quarto file

1.  File > New File > Quarto document

2.  Details : Titre / Auteur / HTML

3.  Create

2. IDE Studio

The basics - IDE Studio

1. Create a quarto file

1.  File > New File > Quarto document

2.  Details : Titre / Auteur / HTML

3.  Create

2. IDE Studio

The basics - IDE Studio

1. Create a quarto file

1.  File > New File > Quarto document

2.  Details : Titre / Auteur / HTML

3.  Create

2. IDE Studio

The basics - IDE Studio

1. Create a quarto file

1.  File > New File > Quarto document

2.  Details : Titre / Auteur / HTML

3.  Create

2. IDE Studio

The basics - IDE Studio

The basics - YAML header

 ---
title: "formation-quarto"
author:
  - name: Clara Lerebourg
    orcid: 0000-0003-0589-8932
    email: Clara.Lerebourg@ird.fr
    institution: IRD/MARBEC/OB7
  - name: Mathieu Depetris
    orcid: 0000-0001-8080-0531
    email: Clara.Lerebourg@ird.fr
    institution: IRD/MARBEC/OB7
  - name: Julien Lebranchu
    orcid: 0000-0002-7759-0534
    email: Julien.Lebranchu@ird.fr
    institution: IRD/MARBEC/OB7
toc: true
number-sections: true
format: 
  html :
    code-fold: true
prefer-html: true
---
  • toc : if true add a table of content

  • Formats : html, pdf, docx

  • code-fold : hide r code

  • prefer-html : displays images when saving in word and pdf format

The basics - Anatomy of the document

Titles

Markdown Syntax Output
# Header 1

Header 1

## Header 2

Header 2

### Header 3

Header 3

#### Header 4

Header 4

##### Header 5
Header 5
###### Header 6
Header 6

The basics - Anatomy of the document

Syntax

Markdown Syntax Output
*italics* and **bold**
italics and bold
superscript^2^ / subscript~2~
superscript2 / subscript2
~~strikethrough~~
strikethrough
`verbatim code`
verbatim code

The basics - Anatomy of the document

Add a picture

![](image/polar-axis.png){.absolute left="350" top="175" width="80%"}

The basics - Anatomy of the document

Add two columns

::: columns
::: {.column width="50%}
Colonne 1
:::

::: {.column width="50%}
Colonne 2
:::

:::

Column 1

Column 2

Your Turn

  • Create a document Quarto qmd
  • Write the Yaml
  • Write a texte with syntax and headers
  • Add a picture and center it in the middle of the doc
  • Create two colomns
05:00

Code chunks

What we are going to see

Deepening our knowledge:

  • Libraries and dataframe

  • Figures

  • Tables

  • Text

  • List

Libraries and dataframes

Like in every script you need to start with the libraries

library(ggplot2)
library(dplyr)
library(kableExtra)
library(tidyverse)
library(fishi)

Use the dataframe for fishi

dataframe <- read_csv("dataframe_fishi.csv")

Figures

fishing_capacity(dataframe = dataframe)

Figures

#| label: fig-fishing-capacity
#| fig-cap: "Annual changes in the number of vessels"
#| fig-width: 10
#| fig-height: 10

fishing_capacity(dataframe = dataframe)
Figure 1: Annual changes in the number of vessels

Figures

#| fig-height: 7
#| fig-width: 7
#| label: fig-fishing-capacity-2
#| fig-cap: "Annual changes in the number of vessels"
#| fig-subcap:
#|   - "Color by number of cylinders“
#|   - "Color by engine displacement, in liters“
#| layout-ncol: 2

fishi::fishing_capacity(dataframe = dataframe)
fishi::fishing_capacity(dataframe = dataframe)

Tables

#| label: table-mpg

mpg
# A tibble: 234 × 11
   manufacturer model      displ  year   cyl trans drv     cty   hwy fl    class
   <chr>        <chr>      <dbl> <int> <int> <chr> <chr> <int> <int> <chr> <chr>
 1 audi         a4           1.8  1999     4 auto… f        18    29 p     comp…
 2 audi         a4           1.8  1999     4 manu… f        21    29 p     comp…
 3 audi         a4           2    2008     4 manu… f        20    31 p     comp…
 4 audi         a4           2    2008     4 auto… f        21    30 p     comp…
 5 audi         a4           2.8  1999     6 auto… f        16    26 p     comp…
 6 audi         a4           2.8  1999     6 manu… f        18    26 p     comp…
 7 audi         a4           3.1  2008     6 auto… f        18    27 p     comp…
 8 audi         a4 quattro   1.8  1999     4 manu… 4        18    26 p     comp…
 9 audi         a4 quattro   1.8  1999     4 auto… 4        16    25 p     comp…
10 audi         a4 quattro   2    2008     4 manu… 4        20    28 p     comp…
# ℹ 224 more rows

Tables

#| label: table-mpg-1

kable(mpg) %>% 
 kable_classic(c("hover", 
                 "condensed"),
               font_size = 14)
manufacturer model displ year cyl trans drv cty hwy fl class
audi a4 1.8 1999 4 auto(l5) f 18 29 p compact
audi a4 1.8 1999 4 manual(m5) f 21 29 p compact
audi a4 2.0 2008 4 manual(m6) f 20 31 p compact
audi a4 2.0 2008 4 auto(av) f 21 30 p compact
audi a4 2.8 1999 6 auto(l5) f 16 26 p compact
audi a4 2.8 1999 6 manual(m5) f 18 26 p compact
audi a4 3.1 2008 6 auto(av) f 18 27 p compact
audi a4 quattro 1.8 1999 4 manual(m5) 4 18 26 p compact
audi a4 quattro 1.8 1999 4 auto(l5) 4 16 25 p compact
audi a4 quattro 2.0 2008 4 manual(m6) 4 20 28 p compact
audi a4 quattro 2.0 2008 4 auto(s6) 4 19 27 p compact
audi a4 quattro 2.8 1999 6 auto(l5) 4 15 25 p compact
audi a4 quattro 2.8 1999 6 manual(m5) 4 17 25 p compact
audi a4 quattro 3.1 2008 6 auto(s6) 4 17 25 p compact
audi a4 quattro 3.1 2008 6 manual(m6) 4 15 25 p compact
audi a6 quattro 2.8 1999 6 auto(l5) 4 15 24 p midsize
audi a6 quattro 3.1 2008 6 auto(s6) 4 17 25 p midsize
audi a6 quattro 4.2 2008 8 auto(s6) 4 16 23 p midsize
chevrolet c1500 suburban 2wd 5.3 2008 8 auto(l4) r 14 20 r suv
chevrolet c1500 suburban 2wd 5.3 2008 8 auto(l4) r 11 15 e suv
chevrolet c1500 suburban 2wd 5.3 2008 8 auto(l4) r 14 20 r suv
chevrolet c1500 suburban 2wd 5.7 1999 8 auto(l4) r 13 17 r suv
chevrolet c1500 suburban 2wd 6.0 2008 8 auto(l4) r 12 17 r suv
chevrolet corvette 5.7 1999 8 manual(m6) r 16 26 p 2seater
chevrolet corvette 5.7 1999 8 auto(l4) r 15 23 p 2seater
chevrolet corvette 6.2 2008 8 manual(m6) r 16 26 p 2seater
chevrolet corvette 6.2 2008 8 auto(s6) r 15 25 p 2seater
chevrolet corvette 7.0 2008 8 manual(m6) r 15 24 p 2seater
chevrolet k1500 tahoe 4wd 5.3 2008 8 auto(l4) 4 14 19 r suv
chevrolet k1500 tahoe 4wd 5.3 2008 8 auto(l4) 4 11 14 e suv
chevrolet k1500 tahoe 4wd 5.7 1999 8 auto(l4) 4 11 15 r suv
chevrolet k1500 tahoe 4wd 6.5 1999 8 auto(l4) 4 14 17 d suv
chevrolet malibu 2.4 1999 4 auto(l4) f 19 27 r midsize
chevrolet malibu 2.4 2008 4 auto(l4) f 22 30 r midsize
chevrolet malibu 3.1 1999 6 auto(l4) f 18 26 r midsize
chevrolet malibu 3.5 2008 6 auto(l4) f 18 29 r midsize
chevrolet malibu 3.6 2008 6 auto(s6) f 17 26 r midsize
dodge caravan 2wd 2.4 1999 4 auto(l3) f 18 24 r minivan
dodge caravan 2wd 3.0 1999 6 auto(l4) f 17 24 r minivan
dodge caravan 2wd 3.3 1999 6 auto(l4) f 16 22 r minivan
dodge caravan 2wd 3.3 1999 6 auto(l4) f 16 22 r minivan
dodge caravan 2wd 3.3 2008 6 auto(l4) f 17 24 r minivan
dodge caravan 2wd 3.3 2008 6 auto(l4) f 17 24 r minivan
dodge caravan 2wd 3.3 2008 6 auto(l4) f 11 17 e minivan
dodge caravan 2wd 3.8 1999 6 auto(l4) f 15 22 r minivan
dodge caravan 2wd 3.8 1999 6 auto(l4) f 15 21 r minivan
dodge caravan 2wd 3.8 2008 6 auto(l6) f 16 23 r minivan
dodge caravan 2wd 4.0 2008 6 auto(l6) f 16 23 r minivan
dodge dakota pickup 4wd 3.7 2008 6 manual(m6) 4 15 19 r pickup
dodge dakota pickup 4wd 3.7 2008 6 auto(l4) 4 14 18 r pickup
dodge dakota pickup 4wd 3.9 1999 6 auto(l4) 4 13 17 r pickup
dodge dakota pickup 4wd 3.9 1999 6 manual(m5) 4 14 17 r pickup
dodge dakota pickup 4wd 4.7 2008 8 auto(l5) 4 14 19 r pickup
dodge dakota pickup 4wd 4.7 2008 8 auto(l5) 4 14 19 r pickup
dodge dakota pickup 4wd 4.7 2008 8 auto(l5) 4 9 12 e pickup
dodge dakota pickup 4wd 5.2 1999 8 manual(m5) 4 11 17 r pickup
dodge dakota pickup 4wd 5.2 1999 8 auto(l4) 4 11 15 r pickup
dodge durango 4wd 3.9 1999 6 auto(l4) 4 13 17 r suv
dodge durango 4wd 4.7 2008 8 auto(l5) 4 13 17 r suv
dodge durango 4wd 4.7 2008 8 auto(l5) 4 9 12 e suv
dodge durango 4wd 4.7 2008 8 auto(l5) 4 13 17 r suv
dodge durango 4wd 5.2 1999 8 auto(l4) 4 11 16 r suv
dodge durango 4wd 5.7 2008 8 auto(l5) 4 13 18 r suv
dodge durango 4wd 5.9 1999 8 auto(l4) 4 11 15 r suv
dodge ram 1500 pickup 4wd 4.7 2008 8 manual(m6) 4 12 16 r pickup
dodge ram 1500 pickup 4wd 4.7 2008 8 auto(l5) 4 9 12 e pickup
dodge ram 1500 pickup 4wd 4.7 2008 8 auto(l5) 4 13 17 r pickup
dodge ram 1500 pickup 4wd 4.7 2008 8 auto(l5) 4 13 17 r pickup
dodge ram 1500 pickup 4wd 4.7 2008 8 manual(m6) 4 12 16 r pickup
dodge ram 1500 pickup 4wd 4.7 2008 8 manual(m6) 4 9 12 e pickup
dodge ram 1500 pickup 4wd 5.2 1999 8 auto(l4) 4 11 15 r pickup
dodge ram 1500 pickup 4wd 5.2 1999 8 manual(m5) 4 11 16 r pickup
dodge ram 1500 pickup 4wd 5.7 2008 8 auto(l5) 4 13 17 r pickup
dodge ram 1500 pickup 4wd 5.9 1999 8 auto(l4) 4 11 15 r pickup
ford expedition 2wd 4.6 1999 8 auto(l4) r 11 17 r suv
ford expedition 2wd 5.4 1999 8 auto(l4) r 11 17 r suv
ford expedition 2wd 5.4 2008 8 auto(l6) r 12 18 r suv
ford explorer 4wd 4.0 1999 6 auto(l5) 4 14 17 r suv
ford explorer 4wd 4.0 1999 6 manual(m5) 4 15 19 r suv
ford explorer 4wd 4.0 1999 6 auto(l5) 4 14 17 r suv
ford explorer 4wd 4.0 2008 6 auto(l5) 4 13 19 r suv
ford explorer 4wd 4.6 2008 8 auto(l6) 4 13 19 r suv
ford explorer 4wd 5.0 1999 8 auto(l4) 4 13 17 r suv
ford f150 pickup 4wd 4.2 1999 6 auto(l4) 4 14 17 r pickup
ford f150 pickup 4wd 4.2 1999 6 manual(m5) 4 14 17 r pickup
ford f150 pickup 4wd 4.6 1999 8 manual(m5) 4 13 16 r pickup
ford f150 pickup 4wd 4.6 1999 8 auto(l4) 4 13 16 r pickup
ford f150 pickup 4wd 4.6 2008 8 auto(l4) 4 13 17 r pickup
ford f150 pickup 4wd 5.4 1999 8 auto(l4) 4 11 15 r pickup
ford f150 pickup 4wd 5.4 2008 8 auto(l4) 4 13 17 r pickup
ford mustang 3.8 1999 6 manual(m5) r 18 26 r subcompact
ford mustang 3.8 1999 6 auto(l4) r 18 25 r subcompact
ford mustang 4.0 2008 6 manual(m5) r 17 26 r subcompact
ford mustang 4.0 2008 6 auto(l5) r 16 24 r subcompact
ford mustang 4.6 1999 8 auto(l4) r 15 21 r subcompact
ford mustang 4.6 1999 8 manual(m5) r 15 22 r subcompact
ford mustang 4.6 2008 8 manual(m5) r 15 23 r subcompact
ford mustang 4.6 2008 8 auto(l5) r 15 22 r subcompact
ford mustang 5.4 2008 8 manual(m6) r 14 20 p subcompact
honda civic 1.6 1999 4 manual(m5) f 28 33 r subcompact
honda civic 1.6 1999 4 auto(l4) f 24 32 r subcompact
honda civic 1.6 1999 4 manual(m5) f 25 32 r subcompact
honda civic 1.6 1999 4 manual(m5) f 23 29 p subcompact
honda civic 1.6 1999 4 auto(l4) f 24 32 r subcompact
honda civic 1.8 2008 4 manual(m5) f 26 34 r subcompact
honda civic 1.8 2008 4 auto(l5) f 25 36 r subcompact
honda civic 1.8 2008 4 auto(l5) f 24 36 c subcompact
honda civic 2.0 2008 4 manual(m6) f 21 29 p subcompact
hyundai sonata 2.4 1999 4 auto(l4) f 18 26 r midsize
hyundai sonata 2.4 1999 4 manual(m5) f 18 27 r midsize
hyundai sonata 2.4 2008 4 auto(l4) f 21 30 r midsize
hyundai sonata 2.4 2008 4 manual(m5) f 21 31 r midsize
hyundai sonata 2.5 1999 6 auto(l4) f 18 26 r midsize
hyundai sonata 2.5 1999 6 manual(m5) f 18 26 r midsize
hyundai sonata 3.3 2008 6 auto(l5) f 19 28 r midsize
hyundai tiburon 2.0 1999 4 auto(l4) f 19 26 r subcompact
hyundai tiburon 2.0 1999 4 manual(m5) f 19 29 r subcompact
hyundai tiburon 2.0 2008 4 manual(m5) f 20 28 r subcompact
hyundai tiburon 2.0 2008 4 auto(l4) f 20 27 r subcompact
hyundai tiburon 2.7 2008 6 auto(l4) f 17 24 r subcompact
hyundai tiburon 2.7 2008 6 manual(m6) f 16 24 r subcompact
hyundai tiburon 2.7 2008 6 manual(m5) f 17 24 r subcompact
jeep grand cherokee 4wd 3.0 2008 6 auto(l5) 4 17 22 d suv
jeep grand cherokee 4wd 3.7 2008 6 auto(l5) 4 15 19 r suv
jeep grand cherokee 4wd 4.0 1999 6 auto(l4) 4 15 20 r suv
jeep grand cherokee 4wd 4.7 1999 8 auto(l4) 4 14 17 r suv
jeep grand cherokee 4wd 4.7 2008 8 auto(l5) 4 9 12 e suv
jeep grand cherokee 4wd 4.7 2008 8 auto(l5) 4 14 19 r suv
jeep grand cherokee 4wd 5.7 2008 8 auto(l5) 4 13 18 r suv
jeep grand cherokee 4wd 6.1 2008 8 auto(l5) 4 11 14 p suv
land rover range rover 4.0 1999 8 auto(l4) 4 11 15 p suv
land rover range rover 4.2 2008 8 auto(s6) 4 12 18 r suv
land rover range rover 4.4 2008 8 auto(s6) 4 12 18 r suv
land rover range rover 4.6 1999 8 auto(l4) 4 11 15 p suv
lincoln navigator 2wd 5.4 1999 8 auto(l4) r 11 17 r suv
lincoln navigator 2wd 5.4 1999 8 auto(l4) r 11 16 p suv
lincoln navigator 2wd 5.4 2008 8 auto(l6) r 12 18 r suv
mercury mountaineer 4wd 4.0 1999 6 auto(l5) 4 14 17 r suv
mercury mountaineer 4wd 4.0 2008 6 auto(l5) 4 13 19 r suv
mercury mountaineer 4wd 4.6 2008 8 auto(l6) 4 13 19 r suv
mercury mountaineer 4wd 5.0 1999 8 auto(l4) 4 13 17 r suv
nissan altima 2.4 1999 4 manual(m5) f 21 29 r compact
nissan altima 2.4 1999 4 auto(l4) f 19 27 r compact
nissan altima 2.5 2008 4 auto(av) f 23 31 r midsize
nissan altima 2.5 2008 4 manual(m6) f 23 32 r midsize
nissan altima 3.5 2008 6 manual(m6) f 19 27 p midsize
nissan altima 3.5 2008 6 auto(av) f 19 26 p midsize
nissan maxima 3.0 1999 6 auto(l4) f 18 26 r midsize
nissan maxima 3.0 1999 6 manual(m5) f 19 25 r midsize
nissan maxima 3.5 2008 6 auto(av) f 19 25 p midsize
nissan pathfinder 4wd 3.3 1999 6 auto(l4) 4 14 17 r suv
nissan pathfinder 4wd 3.3 1999 6 manual(m5) 4 15 17 r suv
nissan pathfinder 4wd 4.0 2008 6 auto(l5) 4 14 20 p suv
nissan pathfinder 4wd 5.6 2008 8 auto(s5) 4 12 18 p suv
pontiac grand prix 3.1 1999 6 auto(l4) f 18 26 r midsize
pontiac grand prix 3.8 1999 6 auto(l4) f 16 26 p midsize
pontiac grand prix 3.8 1999 6 auto(l4) f 17 27 r midsize
pontiac grand prix 3.8 2008 6 auto(l4) f 18 28 r midsize
pontiac grand prix 5.3 2008 8 auto(s4) f 16 25 p midsize
subaru forester awd 2.5 1999 4 manual(m5) 4 18 25 r suv
subaru forester awd 2.5 1999 4 auto(l4) 4 18 24 r suv
subaru forester awd 2.5 2008 4 manual(m5) 4 20 27 r suv
subaru forester awd 2.5 2008 4 manual(m5) 4 19 25 p suv
subaru forester awd 2.5 2008 4 auto(l4) 4 20 26 r suv
subaru forester awd 2.5 2008 4 auto(l4) 4 18 23 p suv
subaru impreza awd 2.2 1999 4 auto(l4) 4 21 26 r subcompact
subaru impreza awd 2.2 1999 4 manual(m5) 4 19 26 r subcompact
subaru impreza awd 2.5 1999 4 manual(m5) 4 19 26 r subcompact
subaru impreza awd 2.5 1999 4 auto(l4) 4 19 26 r subcompact
subaru impreza awd 2.5 2008 4 auto(s4) 4 20 25 p compact
subaru impreza awd 2.5 2008 4 auto(s4) 4 20 27 r compact
subaru impreza awd 2.5 2008 4 manual(m5) 4 19 25 p compact
subaru impreza awd 2.5 2008 4 manual(m5) 4 20 27 r compact
toyota 4runner 4wd 2.7 1999 4 manual(m5) 4 15 20 r suv
toyota 4runner 4wd 2.7 1999 4 auto(l4) 4 16 20 r suv
toyota 4runner 4wd 3.4 1999 6 auto(l4) 4 15 19 r suv
toyota 4runner 4wd 3.4 1999 6 manual(m5) 4 15 17 r suv
toyota 4runner 4wd 4.0 2008 6 auto(l5) 4 16 20 r suv
toyota 4runner 4wd 4.7 2008 8 auto(l5) 4 14 17 r suv
toyota camry 2.2 1999 4 manual(m5) f 21 29 r midsize
toyota camry 2.2 1999 4 auto(l4) f 21 27 r midsize
toyota camry 2.4 2008 4 manual(m5) f 21 31 r midsize
toyota camry 2.4 2008 4 auto(l5) f 21 31 r midsize
toyota camry 3.0 1999 6 auto(l4) f 18 26 r midsize
toyota camry 3.0 1999 6 manual(m5) f 18 26 r midsize
toyota camry 3.5 2008 6 auto(s6) f 19 28 r midsize
toyota camry solara 2.2 1999 4 auto(l4) f 21 27 r compact
toyota camry solara 2.2 1999 4 manual(m5) f 21 29 r compact
toyota camry solara 2.4 2008 4 manual(m5) f 21 31 r compact
toyota camry solara 2.4 2008 4 auto(s5) f 22 31 r compact
toyota camry solara 3.0 1999 6 auto(l4) f 18 26 r compact
toyota camry solara 3.0 1999 6 manual(m5) f 18 26 r compact
toyota camry solara 3.3 2008 6 auto(s5) f 18 27 r compact
toyota corolla 1.8 1999 4 auto(l3) f 24 30 r compact
toyota corolla 1.8 1999 4 auto(l4) f 24 33 r compact
toyota corolla 1.8 1999 4 manual(m5) f 26 35 r compact
toyota corolla 1.8 2008 4 manual(m5) f 28 37 r compact
toyota corolla 1.8 2008 4 auto(l4) f 26 35 r compact
toyota land cruiser wagon 4wd 4.7 1999 8 auto(l4) 4 11 15 r suv
toyota land cruiser wagon 4wd 5.7 2008 8 auto(s6) 4 13 18 r suv
toyota toyota tacoma 4wd 2.7 1999 4 manual(m5) 4 15 20 r pickup
toyota toyota tacoma 4wd 2.7 1999 4 auto(l4) 4 16 20 r pickup
toyota toyota tacoma 4wd 2.7 2008 4 manual(m5) 4 17 22 r pickup
toyota toyota tacoma 4wd 3.4 1999 6 manual(m5) 4 15 17 r pickup
toyota toyota tacoma 4wd 3.4 1999 6 auto(l4) 4 15 19 r pickup
toyota toyota tacoma 4wd 4.0 2008 6 manual(m6) 4 15 18 r pickup
toyota toyota tacoma 4wd 4.0 2008 6 auto(l5) 4 16 20 r pickup
volkswagen gti 2.0 1999 4 manual(m5) f 21 29 r compact
volkswagen gti 2.0 1999 4 auto(l4) f 19 26 r compact
volkswagen gti 2.0 2008 4 manual(m6) f 21 29 p compact
volkswagen gti 2.0 2008 4 auto(s6) f 22 29 p compact
volkswagen gti 2.8 1999 6 manual(m5) f 17 24 r compact
volkswagen jetta 1.9 1999 4 manual(m5) f 33 44 d compact
volkswagen jetta 2.0 1999 4 manual(m5) f 21 29 r compact
volkswagen jetta 2.0 1999 4 auto(l4) f 19 26 r compact
volkswagen jetta 2.0 2008 4 auto(s6) f 22 29 p compact
volkswagen jetta 2.0 2008 4 manual(m6) f 21 29 p compact
volkswagen jetta 2.5 2008 5 auto(s6) f 21 29 r compact
volkswagen jetta 2.5 2008 5 manual(m5) f 21 29 r compact
volkswagen jetta 2.8 1999 6 auto(l4) f 16 23 r compact
volkswagen jetta 2.8 1999 6 manual(m5) f 17 24 r compact
volkswagen new beetle 1.9 1999 4 manual(m5) f 35 44 d subcompact
volkswagen new beetle 1.9 1999 4 auto(l4) f 29 41 d subcompact
volkswagen new beetle 2.0 1999 4 manual(m5) f 21 29 r subcompact
volkswagen new beetle 2.0 1999 4 auto(l4) f 19 26 r subcompact
volkswagen new beetle 2.5 2008 5 manual(m5) f 20 28 r subcompact
volkswagen new beetle 2.5 2008 5 auto(s6) f 20 29 r subcompact
volkswagen passat 1.8 1999 4 manual(m5) f 21 29 p midsize
volkswagen passat 1.8 1999 4 auto(l5) f 18 29 p midsize
volkswagen passat 2.0 2008 4 auto(s6) f 19 28 p midsize
volkswagen passat 2.0 2008 4 manual(m6) f 21 29 p midsize
volkswagen passat 2.8 1999 6 auto(l5) f 16 26 p midsize
volkswagen passat 2.8 1999 6 manual(m5) f 18 26 p midsize
volkswagen passat 3.6 2008 6 auto(s6) f 17 26 p midsize

Text

The plots in @fig-fishing-capacity show the annual changes 
in the number of purse seiners by tonnage categories and total carrying capacity

The plots in Figure 1 show the annual changes in the number of purse seiners by tonnage categories and total carrying capacity

Text

mean_cty <- round(mean(mpg$cty), 2) 
mean_hwy <- round(mean(mpg$hwy), 2)
 
 There are `r nrow(mpg)` observations in our data. The average city mileage of the cars in our data is `r mean_cty` and the average highway mileage is `r mean_hwy`.

Text

mean_cty <- round(mean(mpg$cty), 2) 
mean_hwy <- round(mean(mpg$hwy), 2)
 
 There are `r nrow(mpg)` observations in our data. The average city mileage of the cars in our data is `r mean_cty` and the average highway mileage is `r mean_hwy`.
There are 234 observations in our data.
The average city mileage of the cars in our data is 16.86 and the average highway mileage is 23.44.  

List

Made list - Incremental


::: {.incremental}

- Eat spaghetti
- Drink wine

:::
  • Eat spaghetti
  • Drink wine

List

Made list - Non incremental


::: {.nonincremental}

- Eat spaghetti
- Drink wine

:::
  • Eat spaghetti
  • Drink wine

Your Turn

  • Display a fishi figure : Add a title and define the size
  • Display a table
  • Write a text using the values in the mpg table
10:00

Create a presentation

Create a presentation

1. Create a quarto presentation

1.  File > New File > Quarto presentation

2.  Details : Titre / Auteur / HTML

3.  Create

Create a presentation

2. Create slides

Slides are defined by level 1 titles (#) for a title on a page, or level 2 (##) :

Create a presentation

2. Create slides

Slides are defined by level 1 titles (#) for a title on a page, or level 2 (##) :

---
title: "Habits"
author: "John Doe"
format: revealjs
---

# In the morning

## Getting up

- Turn off alarm
- Get out of bed

## Breakfast

- Eat eggs
- Drink coffee

Code animation

For animation : Title and {auto-animate=“true”}

For smaller slide : Title and {.smaller}

Fragments

::: {.fragment}
Fade in
:::

::: {.fragment .fade-out}
Fade out
:::

::: {.fragment .highlight-red}
Highlight red
:::

::: {.fragment .fade-in-then-out}
Fade in, then out
:::

::: {.fragment .fade-up}
Slide up while fading in
:::

Fade in

Fade out

Highlight red

Fade in, then out

Slide up while fading in

Your Turn

  • Create a presentation Quarto qmd
  • Write the Yaml
  • Create multiple slides
    • One with a picture in the middle
    • One with fragments
    • One with animations
    • One with the code on the left and a fishi figure on the right
20:00

Advanced class

Advanced class

More informations :

  • References
  • How to change the theme ?
  • Notes, warning and comments

References

Write /ci in the quarto document and select “Citation… Reference to a source”.

References

Write /ci in the quarto document and select “Citation… Reference to a source”.

Change theme

HTML documents rendered with Quarto use Bootstrap 5 by default. This can be disabled or customized via the theme option:

theme: default # bootstrap 5 default
theme: cosmo   # cosmo bootswatch theme
theme: pandoc  # pandoc default html treatment
theme: none    # no theme css added to document

Quarto includes 25 themes from the Bootswatch project (for example, the website uses the cosmo theme) : https://bootswatch.com/

Change theme

HTML documents rendered with Quarto use Bootstrap 5 by default. This can be disabled or customized via the theme option:

theme: default # bootstrap 5 default
theme: cosmo   # cosmo bootswatch theme
theme: pandoc  # pandoc default html treatment
theme: none    # no theme css added to document

Quarto includes 25 themes from the Bootswatch project (for example, the website uses the cosmo theme) : https://bootswatch.com/

Use of any of these themes via the theme option. For example:

format:
  html:
    theme: united

Notes, warnings and comments

:::{.callout-note}
Note that there are five types of callouts, including: 
`note`, `tip`, `warning`, `caution`, and `important`.
:::

Note

Note that there are five types of callouts, including: note, tip, warning, caution, and important.

Tip

Note that there are five types of callouts, including: note, tip, warning, caution, and important.

Warning

Note that there are five types of callouts, including: note, tip, warning, caution, and important.

Caution

Note that there are five types of callouts, including: note, tip, warning, caution, and important.

Last but not least

Quarto Extension

Quarto have multiple extensions that you can integrate in your documents:

For example:

More details on

Ob7 extensions

You can use our own extension/theme:

Note

All improvments are welcomed, via GitHub/Gitlab issues