This repository contains the slides and the material for the Café des Doctorants.
It is a quite thorough introduction to 📦 ggplot2
, with some advanced concepts.
⚠ Written in French! ⚠
Browse the slides!
Download the slides in PDF! (not always updated)
Slides built with 📦 xaringan, an R wrapper around remark.js.
Just clone the repository and open the html!
To build the presentation, one needs the 📦 tidyverse
package and some required packages to build the individual slides:
The HTML slides are built by knitting the file index.Rmd in the docs subdirectory.
To build the PDF slides, one needs the package 📦 pagedown
with Chrome installed.
A small makefile is supplied.
The presentation was made as a weekend project, using R Markdown and the package 📦 xaringan.
It contains several customizations, tricks and hacks:
-
basic
knitr
stuff:
usage of child chunks to avoid recompiling everything, witheval=FALSE
as chunk options. -
the "advanced" CSS ribbon on difficult slides:
docs/assets/css/ribbon-advanced.css
It is always present (layout slide), but shown only if a slide has CSS classslide-class-advanced
. -
the half-opaque overlay with CSS id
#overlay
, to shield the content behind a popup.
It is always present (layout slide) but hidden. Currently not used! -
Code wrapping in code chunks:
docs/assets/css/custom.css
.
CSS class.left-code
. Has some issues with spaces, but it works more or less. -
the
remarkjs
macro to link to CRAN:docs/assets/js/macros.js
Usage: write somewhere![:package_cran xaringan]
to make a pretty link with emoji. -
some CSS popups:
docs/assets/css/custom.css
Usage: Make adiv
with classheavy-box
-
Embedding
plotly
intoxaringan
using the 📦htmltools
hack.
Save theplotly
object tohtml
file, then manually embed it in iframe. -
Embedding a previously-made
gganimate
animation by saving todocs/assets/img
directory (offline). -
Gradient background on CSS class
slide-class-advanced
slides:docs/assets/css/custom.css
.
(To CSS pros: I'm sorry!)