SlideShare una empresa de Scribd logo
1 de 35
Descargar para leer sin conexión
La famille *down
Nathalie Vialaneix, INRA/MIAT
RUG Toulouse, November 18th 2019
1 / 35
What is Markdown? (*.md files)
According to Wikipedia,
Markdown is a lightweight markup language with plain text formatting syntax. Its
design allows it to be converted to many output formats.
2 / 35
Why Markdown?
formatting text and documents is easy
probably the most used lightweight markup language for numeric documents (especially
technical documentations)
But: is sometimes a bit limited if you want to have custom outputs
3 / 35
What is RMarkdown? (*.Rmd files)
developed by RStudio (and especially by Yihui Xie)
combines Markdown documents with R scripts (or python, C++, bash, ...) to produce
dynamic (and even interactive) documents
4 / 35
What is RMarkdown? (*.Rmd files)
developed by RStudio (and especially by Yihui Xie)
combines Markdown documents with R scripts (or python, C++, bash, ...) to produce
dynamic (and even interactive) documents
also available as R notebooks (similar to Jupyter notebooks)
5 / 35
Basic RMarkdown documents
6 / 35
What do you need? (certified exact on
linux)
R
RStudio (not mandatory but highly recommended) and if you don't know how to install
it on linux, please, ask your sysadmin
packages: at least knitr but other packages (rmarkdown, markdown, ...)
pandoc to obtain different output types from *.md files: Rmd md (with pandoc)
HTML
it is best to have installed to render maths or obtain PDF documents
Basic demo...
→ →
LT XA
E
7 / 35
Yaml headers
8 / 35
Yaml headers
9 / 35
Yaml headers
10 / 35
Text formatting
11 / 35
Text formatting
12 / 35
Code chunk and options
Inline code can be included with
13 / 35
Code chunk and options
Types of chunks:
14 / 35
Code chunk and options
A few useful options:
eval=TRUE/FALSE: run (or not) the code in the chunk
include=TRUE/FALSE: include (or not) the chunk in the final document
echo=TRUE/FALSE: include (or not) the output of the code in the final document
results='markup'/'hide'/'asis'/'hold': display the output of the code
normally/not/as it is (useful when combined with xtable for HTML outputs of tables
for instance)/all in a row after the code chunk is displayed (and not one by one)
error/message/warning=TRUE/FALSE: display (or not) the different types of
messages obtained from the code
cache=TRUE/FALSE: cache the result of the chunk
fig.width/height/align/cap/...: different options on rendering of figures
15 / 35
Run code and output types
Run the whole document:
Run interactively:
16 / 35
Run code and output types
Run the whole document externally:
# render document
knitr::render("mybeautifuldoc.Rmd", output_format = "HTML",
encoding = "UTF-8")
# extract R code from chunk
knitr::purl("mybeautifuldoc.Rmd")
Useful to run a report with computationally intensive code on a server! See:
http://www.nathalievialaneix.eu/doc/pdf/tutoR_cluster.pdf
17 / 35
Run code and output types
HTML: often light and can include interactive graphics (with ggplotly for instance)
HTML and equations can be included directly in the document
But: problems rendering equations without internet connexion, you need to copy
several folders in addition to the file to make it work
problems partially solved with the option: self_contained: true (in
HTML headers)
PDF: self-contained but often heavier, needs installed
usually longer to knit (pandoc produces a TeX document and then is run)
can account for options in the headers (including bibliography)
can use the power of to obtain multiple version documents (student and
teacher versions for instance)
(and, of course, forget Word!)
LT XA
E
LT XA
E
LT XA
E
LT XA
E
LT XA
E
18 / 35
Advanced options for RMarkdown
documents
19 / 35
Appearance and style in HTML
documents
theme (in header) specifies the Bootswatch theme to use
highlight (in header) specifies the highlighting style to use (supports tango,
pygments, kate, monochrome, espresso, zenburn, haddock,
breezedark and textmate)
Or: you can use your own CSS with css (in header)
20 / 35
options in PDF documentsLT XA
E
21 / 35
options in PDF documents
Bibliography is managed using:
the citation engine (default is pandoc-citeproc):
citation_package: natbib (header, in pdf_document)
citation_package: biblatex (header, in pdf_document)
the bibtex file: bibliograph: mybib.bib (header, in pdf_document)
LT XA
E
22 / 35
options in PDF documents
More custom options in headers:
LT XA
E
23 / 35
multiple version document
if version1 
... in teacher version only
fi
LT XA
E
24 / 35
A very cool stuff: parameters!
How were useR! invoices generated (and sent)?
and then, used in the Rmd file through params$participant, params$name, ...
25 / 35
A very cool stuff: parameters!
... or passed externally using render:
## loop over users ##################################################
render("invoice-base.Rmd",
params = list(participant = paste(users$FIRSTNAME[cur], users$
name = users$"Billing.name"[cur],
address1 = users$"Billing.address..street."[cur]
address2 = users$"Billing.address..other."[cur],
address3 = users$"Billing.address..state..town.a
country = users$"Billing.address..country."[cur]
uid = users$UID[cur],
date = gsub("-", "/", as.character(as.Date(saved
total = users$Amount[cur],
method = users$Payment.type[cur],
refpaybox = users$transaction[cur]
),
output_file = paste0("invoices/", file_names[cur]))
# send email
send.mail(from = "contact@user2019.fr",
to = ...,
attach.files = paste0("invoices/", file_names[cur]))
26 / 35
A very cool stuff: parameters!
used to produce automatic report on standard analyses (e.g., differential analysis of
RNAseq data with only two conditions)
used to run standard analyses on multiple datasets at once
parameters can be set interactively using the knit buttom
constrains can be declared for parameters
27 / 35
Want to know more?
R Markdown cheatsheet
R Markdown reference
R Markdown book
28 / 35
Other types of documents
29 / 35
Slides
Using the same approach, you can make:
R presentation (included in R studio) but with rather limited features
(my old class on R was made using it)
xarigan slides (HTML), also developed by Yihui Xie (see Chapter 7 of the R
Markdown book): easy to use and includes many options but if you want to obtain a
custom result, you better be an HTML/CSS ninja, can be exported in PDF with
pagedown::chrome_print (but I do not recommend it)
this presentation was made with xaringan using the rladies css
binb (binb is not beamer) provides functionality to use themes for beamer directly in
RMarkdown: if you want to obtain a custom result, you better be a ninja, output
PDF, long to compile (as beamer is)
(this seminar has been made using binb)
LT XA
E
30 / 35
Posters
drposter (example is courtesy of Pierre Neuvial)
31 / 35
Documentation for packages
pkgdown: Generate cool package documentation from your package
Example from adjclust
32 / 35
Books
bookdown: generate printer ready books and ebooks from R Markdown
I never used it so no feedback...
33 / 35
Website
blogdown: generate website from RMarkdown pages using hugo (python static website
generator).
The missing data reference website is generated through blogdown and thanks to its hugo
support is automatically published on netlify.
34 / 35
Next to come...?
coffeedown... ?
35 / 35

Más contenido relacionado

Similar a La famille *down

La famille *down
La famille *downLa famille *down
La famille *downtuxette
 
R Introduction
R IntroductionR Introduction
R Introductionschamber
 
Overview of the DITA Open Toolkit
Overview of the DITA Open ToolkitOverview of the DITA Open Toolkit
Overview of the DITA Open ToolkitSuite Solutions
 
Language-agnostic data analysis workflows and reproducible research
Language-agnostic data analysis workflows and reproducible researchLanguage-agnostic data analysis workflows and reproducible research
Language-agnostic data analysis workflows and reproducible researchAndrew Lowe
 
rmarkdown.pdf
rmarkdown.pdfrmarkdown.pdf
rmarkdown.pdfTheZephyr
 
Reproducible research (and literate programming) in R
Reproducible research (and literate programming) in RReproducible research (and literate programming) in R
Reproducible research (and literate programming) in Rliz__is
 
R markdown and Rmdformats
R markdown and RmdformatsR markdown and Rmdformats
R markdown and RmdformatsHoffman Lab
 
Input and output in c
Input and output in cInput and output in c
Input and output in cRachana Joshi
 
The GO Language : From Beginners to Gophers
The GO Language : From Beginners to GophersThe GO Language : From Beginners to Gophers
The GO Language : From Beginners to GophersAlessandro Sanino
 
The Big Documentation Extravaganza
The Big Documentation ExtravaganzaThe Big Documentation Extravaganza
The Big Documentation ExtravaganzaStephan Schmidt
 
RStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdf
RStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdfRStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdf
RStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdfAkshay Sahatpure
 
R package development, create package documentation isabella gollini
R package development, create package documentation   isabella golliniR package development, create package documentation   isabella gollini
R package development, create package documentation isabella golliniDataFest Tbilisi
 
Rmll2010 html5-css3-english
Rmll2010 html5-css3-englishRmll2010 html5-css3-english
Rmll2010 html5-css3-englishFnot
 
C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...
C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...
C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...corehard_by
 
Automating API Documentation
Automating API DocumentationAutomating API Documentation
Automating API DocumentationSelvakumar T S
 
Typescript for the programmers who like javascript
Typescript for the programmers who like javascriptTypescript for the programmers who like javascript
Typescript for the programmers who like javascriptAndrei Sebastian Cîmpean
 
Introduction to knitr - May Sheffield R Users group
Introduction to knitr - May Sheffield R Users groupIntroduction to knitr - May Sheffield R Users group
Introduction to knitr - May Sheffield R Users groupPaul Richards
 
Write effectlively in late x
Write effectlively in late xWrite effectlively in late x
Write effectlively in late xC-CORE
 

Similar a La famille *down (20)

La famille *down
La famille *downLa famille *down
La famille *down
 
R Introduction
R IntroductionR Introduction
R Introduction
 
Rmarkdown cheatsheet-2.0
Rmarkdown cheatsheet-2.0Rmarkdown cheatsheet-2.0
Rmarkdown cheatsheet-2.0
 
Overview of the DITA Open Toolkit
Overview of the DITA Open ToolkitOverview of the DITA Open Toolkit
Overview of the DITA Open Toolkit
 
Language-agnostic data analysis workflows and reproducible research
Language-agnostic data analysis workflows and reproducible researchLanguage-agnostic data analysis workflows and reproducible research
Language-agnostic data analysis workflows and reproducible research
 
rmarkdown.pdf
rmarkdown.pdfrmarkdown.pdf
rmarkdown.pdf
 
Reproducible research (and literate programming) in R
Reproducible research (and literate programming) in RReproducible research (and literate programming) in R
Reproducible research (and literate programming) in R
 
Dart
DartDart
Dart
 
R markdown and Rmdformats
R markdown and RmdformatsR markdown and Rmdformats
R markdown and Rmdformats
 
Input and output in c
Input and output in cInput and output in c
Input and output in c
 
The GO Language : From Beginners to Gophers
The GO Language : From Beginners to GophersThe GO Language : From Beginners to Gophers
The GO Language : From Beginners to Gophers
 
The Big Documentation Extravaganza
The Big Documentation ExtravaganzaThe Big Documentation Extravaganza
The Big Documentation Extravaganza
 
RStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdf
RStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdfRStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdf
RStudio_s_R_Markdown_documentation_Cheat_Cheet__1677232908.pdf
 
R package development, create package documentation isabella gollini
R package development, create package documentation   isabella golliniR package development, create package documentation   isabella gollini
R package development, create package documentation isabella gollini
 
Rmll2010 html5-css3-english
Rmll2010 html5-css3-englishRmll2010 html5-css3-english
Rmll2010 html5-css3-english
 
C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...
C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...
C++ CoreHard Autumn 2018. Text Formatting For a Future Range-Based Standard L...
 
Automating API Documentation
Automating API DocumentationAutomating API Documentation
Automating API Documentation
 
Typescript for the programmers who like javascript
Typescript for the programmers who like javascriptTypescript for the programmers who like javascript
Typescript for the programmers who like javascript
 
Introduction to knitr - May Sheffield R Users group
Introduction to knitr - May Sheffield R Users groupIntroduction to knitr - May Sheffield R Users group
Introduction to knitr - May Sheffield R Users group
 
Write effectlively in late x
Write effectlively in late xWrite effectlively in late x
Write effectlively in late x
 

Más de tuxette

Racines en haut et feuilles en bas : les arbres en maths
Racines en haut et feuilles en bas : les arbres en mathsRacines en haut et feuilles en bas : les arbres en maths
Racines en haut et feuilles en bas : les arbres en mathstuxette
 
Méthodes à noyaux pour l’intégration de données hétérogènes
Méthodes à noyaux pour l’intégration de données hétérogènesMéthodes à noyaux pour l’intégration de données hétérogènes
Méthodes à noyaux pour l’intégration de données hétérogènestuxette
 
Méthodologies d'intégration de données omiques
Méthodologies d'intégration de données omiquesMéthodologies d'intégration de données omiques
Méthodologies d'intégration de données omiquestuxette
 
Projets autour de l'Hi-C
Projets autour de l'Hi-CProjets autour de l'Hi-C
Projets autour de l'Hi-Ctuxette
 
Can deep learning learn chromatin structure from sequence?
Can deep learning learn chromatin structure from sequence?Can deep learning learn chromatin structure from sequence?
Can deep learning learn chromatin structure from sequence?tuxette
 
Multi-omics data integration methods: kernel and other machine learning appro...
Multi-omics data integration methods: kernel and other machine learning appro...Multi-omics data integration methods: kernel and other machine learning appro...
Multi-omics data integration methods: kernel and other machine learning appro...tuxette
 
ASTERICS : une application pour intégrer des données omiques
ASTERICS : une application pour intégrer des données omiquesASTERICS : une application pour intégrer des données omiques
ASTERICS : une application pour intégrer des données omiquestuxette
 
Autour des projets Idefics et MetaboWean
Autour des projets Idefics et MetaboWeanAutour des projets Idefics et MetaboWean
Autour des projets Idefics et MetaboWeantuxette
 
Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...
Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...
Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...tuxette
 
Apprentissage pour la biologie moléculaire et l’analyse de données omiques
Apprentissage pour la biologie moléculaire et l’analyse de données omiquesApprentissage pour la biologie moléculaire et l’analyse de données omiques
Apprentissage pour la biologie moléculaire et l’analyse de données omiquestuxette
 
Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...
Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...
Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...tuxette
 
Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...
Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...
Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...tuxette
 
Journal club: Validation of cluster analysis results on validation data
Journal club: Validation of cluster analysis results on validation dataJournal club: Validation of cluster analysis results on validation data
Journal club: Validation of cluster analysis results on validation datatuxette
 
Overfitting or overparametrization?
Overfitting or overparametrization?Overfitting or overparametrization?
Overfitting or overparametrization?tuxette
 
Selective inference and single-cell differential analysis
Selective inference and single-cell differential analysisSelective inference and single-cell differential analysis
Selective inference and single-cell differential analysistuxette
 
SOMbrero : un package R pour les cartes auto-organisatrices
SOMbrero : un package R pour les cartes auto-organisatricesSOMbrero : un package R pour les cartes auto-organisatrices
SOMbrero : un package R pour les cartes auto-organisatricestuxette
 
Graph Neural Network for Phenotype Prediction
Graph Neural Network for Phenotype PredictionGraph Neural Network for Phenotype Prediction
Graph Neural Network for Phenotype Predictiontuxette
 
A short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction modelsA short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction modelstuxette
 
Explanable models for time series with random forest
Explanable models for time series with random forestExplanable models for time series with random forest
Explanable models for time series with random foresttuxette
 
Présentation du projet ASTERICS
Présentation du projet ASTERICSPrésentation du projet ASTERICS
Présentation du projet ASTERICStuxette
 

Más de tuxette (20)

Racines en haut et feuilles en bas : les arbres en maths
Racines en haut et feuilles en bas : les arbres en mathsRacines en haut et feuilles en bas : les arbres en maths
Racines en haut et feuilles en bas : les arbres en maths
 
Méthodes à noyaux pour l’intégration de données hétérogènes
Méthodes à noyaux pour l’intégration de données hétérogènesMéthodes à noyaux pour l’intégration de données hétérogènes
Méthodes à noyaux pour l’intégration de données hétérogènes
 
Méthodologies d'intégration de données omiques
Méthodologies d'intégration de données omiquesMéthodologies d'intégration de données omiques
Méthodologies d'intégration de données omiques
 
Projets autour de l'Hi-C
Projets autour de l'Hi-CProjets autour de l'Hi-C
Projets autour de l'Hi-C
 
Can deep learning learn chromatin structure from sequence?
Can deep learning learn chromatin structure from sequence?Can deep learning learn chromatin structure from sequence?
Can deep learning learn chromatin structure from sequence?
 
Multi-omics data integration methods: kernel and other machine learning appro...
Multi-omics data integration methods: kernel and other machine learning appro...Multi-omics data integration methods: kernel and other machine learning appro...
Multi-omics data integration methods: kernel and other machine learning appro...
 
ASTERICS : une application pour intégrer des données omiques
ASTERICS : une application pour intégrer des données omiquesASTERICS : une application pour intégrer des données omiques
ASTERICS : une application pour intégrer des données omiques
 
Autour des projets Idefics et MetaboWean
Autour des projets Idefics et MetaboWeanAutour des projets Idefics et MetaboWean
Autour des projets Idefics et MetaboWean
 
Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...
Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...
Rserve, renv, flask, Vue.js dans un docker pour intégrer des données omiques ...
 
Apprentissage pour la biologie moléculaire et l’analyse de données omiques
Apprentissage pour la biologie moléculaire et l’analyse de données omiquesApprentissage pour la biologie moléculaire et l’analyse de données omiques
Apprentissage pour la biologie moléculaire et l’analyse de données omiques
 
Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...
Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...
Quelques résultats préliminaires de l'évaluation de méthodes d'inférence de r...
 
Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...
Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...
Intégration de données omiques multi-échelles : méthodes à noyau et autres ap...
 
Journal club: Validation of cluster analysis results on validation data
Journal club: Validation of cluster analysis results on validation dataJournal club: Validation of cluster analysis results on validation data
Journal club: Validation of cluster analysis results on validation data
 
Overfitting or overparametrization?
Overfitting or overparametrization?Overfitting or overparametrization?
Overfitting or overparametrization?
 
Selective inference and single-cell differential analysis
Selective inference and single-cell differential analysisSelective inference and single-cell differential analysis
Selective inference and single-cell differential analysis
 
SOMbrero : un package R pour les cartes auto-organisatrices
SOMbrero : un package R pour les cartes auto-organisatricesSOMbrero : un package R pour les cartes auto-organisatrices
SOMbrero : un package R pour les cartes auto-organisatrices
 
Graph Neural Network for Phenotype Prediction
Graph Neural Network for Phenotype PredictionGraph Neural Network for Phenotype Prediction
Graph Neural Network for Phenotype Prediction
 
A short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction modelsA short and naive introduction to using network in prediction models
A short and naive introduction to using network in prediction models
 
Explanable models for time series with random forest
Explanable models for time series with random forestExplanable models for time series with random forest
Explanable models for time series with random forest
 
Présentation du projet ASTERICS
Présentation du projet ASTERICSPrésentation du projet ASTERICS
Présentation du projet ASTERICS
 

Último

TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...
TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...
TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...ssifa0344
 
Botany 4th semester file By Sumit Kumar yadav.pdf
Botany 4th semester file By Sumit Kumar yadav.pdfBotany 4th semester file By Sumit Kumar yadav.pdf
Botany 4th semester file By Sumit Kumar yadav.pdfSumit Kumar yadav
 
Seismic Method Estimate velocity from seismic data.pptx
Seismic Method Estimate velocity from seismic  data.pptxSeismic Method Estimate velocity from seismic  data.pptx
Seismic Method Estimate velocity from seismic data.pptxAlMamun560346
 
Botany 4th semester series (krishna).pdf
Botany 4th semester series (krishna).pdfBotany 4th semester series (krishna).pdf
Botany 4th semester series (krishna).pdfSumit Kumar yadav
 
Presentation Vikram Lander by Vedansh Gupta.pptx
Presentation Vikram Lander by Vedansh Gupta.pptxPresentation Vikram Lander by Vedansh Gupta.pptx
Presentation Vikram Lander by Vedansh Gupta.pptxgindu3009
 
Kochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRL
Kochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRLKochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRL
Kochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRLkantirani197
 
Bacterial Identification and Classifications
Bacterial Identification and ClassificationsBacterial Identification and Classifications
Bacterial Identification and ClassificationsAreesha Ahmad
 
GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...
GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...
GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...Lokesh Kothari
 
Creating and Analyzing Definitive Screening Designs
Creating and Analyzing Definitive Screening DesignsCreating and Analyzing Definitive Screening Designs
Creating and Analyzing Definitive Screening DesignsNurulAfiqah307317
 
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43bNightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43bSérgio Sacani
 
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...Lokesh Kothari
 
COST ESTIMATION FOR A RESEARCH PROJECT.pptx
COST ESTIMATION FOR A RESEARCH PROJECT.pptxCOST ESTIMATION FOR A RESEARCH PROJECT.pptx
COST ESTIMATION FOR A RESEARCH PROJECT.pptxFarihaAbdulRasheed
 
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...Monika Rani
 
❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.
❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.
❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.Nitya salvi
 
Biological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdfBiological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdfmuntazimhurra
 
GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)Areesha Ahmad
 
Nanoparticles synthesis and characterization​ ​
Nanoparticles synthesis and characterization​  ​Nanoparticles synthesis and characterization​  ​
Nanoparticles synthesis and characterization​ ​kaibalyasahoo82800
 
Disentangling the origin of chemical differences using GHOST
Disentangling the origin of chemical differences using GHOSTDisentangling the origin of chemical differences using GHOST
Disentangling the origin of chemical differences using GHOSTSérgio Sacani
 
Hire 💕 9907093804 Hooghly Call Girls Service Call Girls Agency
Hire 💕 9907093804 Hooghly Call Girls Service Call Girls AgencyHire 💕 9907093804 Hooghly Call Girls Service Call Girls Agency
Hire 💕 9907093804 Hooghly Call Girls Service Call Girls AgencySheetal Arora
 
Recombinant DNA technology (Immunological screening)
Recombinant DNA technology (Immunological screening)Recombinant DNA technology (Immunological screening)
Recombinant DNA technology (Immunological screening)PraveenaKalaiselvan1
 

Último (20)

TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...
TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...
TEST BANK For Radiologic Science for Technologists, 12th Edition by Stewart C...
 
Botany 4th semester file By Sumit Kumar yadav.pdf
Botany 4th semester file By Sumit Kumar yadav.pdfBotany 4th semester file By Sumit Kumar yadav.pdf
Botany 4th semester file By Sumit Kumar yadav.pdf
 
Seismic Method Estimate velocity from seismic data.pptx
Seismic Method Estimate velocity from seismic  data.pptxSeismic Method Estimate velocity from seismic  data.pptx
Seismic Method Estimate velocity from seismic data.pptx
 
Botany 4th semester series (krishna).pdf
Botany 4th semester series (krishna).pdfBotany 4th semester series (krishna).pdf
Botany 4th semester series (krishna).pdf
 
Presentation Vikram Lander by Vedansh Gupta.pptx
Presentation Vikram Lander by Vedansh Gupta.pptxPresentation Vikram Lander by Vedansh Gupta.pptx
Presentation Vikram Lander by Vedansh Gupta.pptx
 
Kochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRL
Kochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRLKochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRL
Kochi ❤CALL GIRL 84099*07087 ❤CALL GIRLS IN Kochi ESCORT SERVICE❤CALL GIRL
 
Bacterial Identification and Classifications
Bacterial Identification and ClassificationsBacterial Identification and Classifications
Bacterial Identification and Classifications
 
GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...
GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...
GUIDELINES ON SIMILAR BIOLOGICS Regulatory Requirements for Marketing Authori...
 
Creating and Analyzing Definitive Screening Designs
Creating and Analyzing Definitive Screening DesignsCreating and Analyzing Definitive Screening Designs
Creating and Analyzing Definitive Screening Designs
 
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43bNightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
Nightside clouds and disequilibrium chemistry on the hot Jupiter WASP-43b
 
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
Labelling Requirements and Label Claims for Dietary Supplements and Recommend...
 
COST ESTIMATION FOR A RESEARCH PROJECT.pptx
COST ESTIMATION FOR A RESEARCH PROJECT.pptxCOST ESTIMATION FOR A RESEARCH PROJECT.pptx
COST ESTIMATION FOR A RESEARCH PROJECT.pptx
 
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
Vip profile Call Girls In Lonavala 9748763073 For Genuine Sex Service At Just...
 
❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.
❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.
❤Jammu Kashmir Call Girls 8617697112 Personal Whatsapp Number 💦✅.
 
Biological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdfBiological Classification BioHack (3).pdf
Biological Classification BioHack (3).pdf
 
GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)
 
Nanoparticles synthesis and characterization​ ​
Nanoparticles synthesis and characterization​  ​Nanoparticles synthesis and characterization​  ​
Nanoparticles synthesis and characterization​ ​
 
Disentangling the origin of chemical differences using GHOST
Disentangling the origin of chemical differences using GHOSTDisentangling the origin of chemical differences using GHOST
Disentangling the origin of chemical differences using GHOST
 
Hire 💕 9907093804 Hooghly Call Girls Service Call Girls Agency
Hire 💕 9907093804 Hooghly Call Girls Service Call Girls AgencyHire 💕 9907093804 Hooghly Call Girls Service Call Girls Agency
Hire 💕 9907093804 Hooghly Call Girls Service Call Girls Agency
 
Recombinant DNA technology (Immunological screening)
Recombinant DNA technology (Immunological screening)Recombinant DNA technology (Immunological screening)
Recombinant DNA technology (Immunological screening)
 

La famille *down

  • 1. La famille *down Nathalie Vialaneix, INRA/MIAT RUG Toulouse, November 18th 2019 1 / 35
  • 2. What is Markdown? (*.md files) According to Wikipedia, Markdown is a lightweight markup language with plain text formatting syntax. Its design allows it to be converted to many output formats. 2 / 35
  • 3. Why Markdown? formatting text and documents is easy probably the most used lightweight markup language for numeric documents (especially technical documentations) But: is sometimes a bit limited if you want to have custom outputs 3 / 35
  • 4. What is RMarkdown? (*.Rmd files) developed by RStudio (and especially by Yihui Xie) combines Markdown documents with R scripts (or python, C++, bash, ...) to produce dynamic (and even interactive) documents 4 / 35
  • 5. What is RMarkdown? (*.Rmd files) developed by RStudio (and especially by Yihui Xie) combines Markdown documents with R scripts (or python, C++, bash, ...) to produce dynamic (and even interactive) documents also available as R notebooks (similar to Jupyter notebooks) 5 / 35
  • 7. What do you need? (certified exact on linux) R RStudio (not mandatory but highly recommended) and if you don't know how to install it on linux, please, ask your sysadmin packages: at least knitr but other packages (rmarkdown, markdown, ...) pandoc to obtain different output types from *.md files: Rmd md (with pandoc) HTML it is best to have installed to render maths or obtain PDF documents Basic demo... → → LT XA E 7 / 35
  • 13. Code chunk and options Inline code can be included with 13 / 35
  • 14. Code chunk and options Types of chunks: 14 / 35
  • 15. Code chunk and options A few useful options: eval=TRUE/FALSE: run (or not) the code in the chunk include=TRUE/FALSE: include (or not) the chunk in the final document echo=TRUE/FALSE: include (or not) the output of the code in the final document results='markup'/'hide'/'asis'/'hold': display the output of the code normally/not/as it is (useful when combined with xtable for HTML outputs of tables for instance)/all in a row after the code chunk is displayed (and not one by one) error/message/warning=TRUE/FALSE: display (or not) the different types of messages obtained from the code cache=TRUE/FALSE: cache the result of the chunk fig.width/height/align/cap/...: different options on rendering of figures 15 / 35
  • 16. Run code and output types Run the whole document: Run interactively: 16 / 35
  • 17. Run code and output types Run the whole document externally: # render document knitr::render("mybeautifuldoc.Rmd", output_format = "HTML", encoding = "UTF-8") # extract R code from chunk knitr::purl("mybeautifuldoc.Rmd") Useful to run a report with computationally intensive code on a server! See: http://www.nathalievialaneix.eu/doc/pdf/tutoR_cluster.pdf 17 / 35
  • 18. Run code and output types HTML: often light and can include interactive graphics (with ggplotly for instance) HTML and equations can be included directly in the document But: problems rendering equations without internet connexion, you need to copy several folders in addition to the file to make it work problems partially solved with the option: self_contained: true (in HTML headers) PDF: self-contained but often heavier, needs installed usually longer to knit (pandoc produces a TeX document and then is run) can account for options in the headers (including bibliography) can use the power of to obtain multiple version documents (student and teacher versions for instance) (and, of course, forget Word!) LT XA E LT XA E LT XA E LT XA E LT XA E 18 / 35
  • 19. Advanced options for RMarkdown documents 19 / 35
  • 20. Appearance and style in HTML documents theme (in header) specifies the Bootswatch theme to use highlight (in header) specifies the highlighting style to use (supports tango, pygments, kate, monochrome, espresso, zenburn, haddock, breezedark and textmate) Or: you can use your own CSS with css (in header) 20 / 35
  • 21. options in PDF documentsLT XA E 21 / 35
  • 22. options in PDF documents Bibliography is managed using: the citation engine (default is pandoc-citeproc): citation_package: natbib (header, in pdf_document) citation_package: biblatex (header, in pdf_document) the bibtex file: bibliograph: mybib.bib (header, in pdf_document) LT XA E 22 / 35
  • 23. options in PDF documents More custom options in headers: LT XA E 23 / 35
  • 24. multiple version document if version1 ... in teacher version only fi LT XA E 24 / 35
  • 25. A very cool stuff: parameters! How were useR! invoices generated (and sent)? and then, used in the Rmd file through params$participant, params$name, ... 25 / 35
  • 26. A very cool stuff: parameters! ... or passed externally using render: ## loop over users ################################################## render("invoice-base.Rmd", params = list(participant = paste(users$FIRSTNAME[cur], users$ name = users$"Billing.name"[cur], address1 = users$"Billing.address..street."[cur] address2 = users$"Billing.address..other."[cur], address3 = users$"Billing.address..state..town.a country = users$"Billing.address..country."[cur] uid = users$UID[cur], date = gsub("-", "/", as.character(as.Date(saved total = users$Amount[cur], method = users$Payment.type[cur], refpaybox = users$transaction[cur] ), output_file = paste0("invoices/", file_names[cur])) # send email send.mail(from = "contact@user2019.fr", to = ..., attach.files = paste0("invoices/", file_names[cur])) 26 / 35
  • 27. A very cool stuff: parameters! used to produce automatic report on standard analyses (e.g., differential analysis of RNAseq data with only two conditions) used to run standard analyses on multiple datasets at once parameters can be set interactively using the knit buttom constrains can be declared for parameters 27 / 35
  • 28. Want to know more? R Markdown cheatsheet R Markdown reference R Markdown book 28 / 35
  • 29. Other types of documents 29 / 35
  • 30. Slides Using the same approach, you can make: R presentation (included in R studio) but with rather limited features (my old class on R was made using it) xarigan slides (HTML), also developed by Yihui Xie (see Chapter 7 of the R Markdown book): easy to use and includes many options but if you want to obtain a custom result, you better be an HTML/CSS ninja, can be exported in PDF with pagedown::chrome_print (but I do not recommend it) this presentation was made with xaringan using the rladies css binb (binb is not beamer) provides functionality to use themes for beamer directly in RMarkdown: if you want to obtain a custom result, you better be a ninja, output PDF, long to compile (as beamer is) (this seminar has been made using binb) LT XA E 30 / 35
  • 31. Posters drposter (example is courtesy of Pierre Neuvial) 31 / 35
  • 32. Documentation for packages pkgdown: Generate cool package documentation from your package Example from adjclust 32 / 35
  • 33. Books bookdown: generate printer ready books and ebooks from R Markdown I never used it so no feedback... 33 / 35
  • 34. Website blogdown: generate website from RMarkdown pages using hugo (python static website generator). The missing data reference website is generated through blogdown and thanks to its hugo support is automatically published on netlify. 34 / 35