+ - 0:00:00
Notes for current slide
Notes for next slide

Microbes on Earth





R - installation and reading

Daniel Vaulot

2021-10-12

1 / 9

Installation

R and R packages

  • Install R

  • Install R studio

  • Install the following packages

    • Data manipulation
    • readxl : Reading Excel files
    • readr : Reading and writing Text files
    • dplyr : Filter and reformat data frames
    • tidyr : Make data "tidy"
    • tibble : Manipulate data frames
    • stringr : Manipulating strings
    • Graphics
    • ggplot2: Graphics
    • Markdown
    • knitr
    • tinytex
    • Metabarcode analysis
    • phyloseq
3 / 9

Reading material

Session 01-03 - Data analysis

Choose of the two text below. Make sure you make the exercises.

Session 04 - Rmarkdown

Session 05 - Phyloseq

4 / 9

Installation - MetaPR2 package

Step 1 - Download the R package

https://daniel-vaulot.fr/html/course-microbes-2021/metapr2-shiny-main.zip

Step 2 - Install package on your computer

  • Unpack Zip file

  • Launch shiny_metapr2.Rproj

5 / 9

Installation - MetaPR2 package

Step 3 - Install the following libraries

### Shiny
install.packages("shiny" )
install.packages("shinyvalidate" ) # For validation of input (easier to use than shinyFeedback)
install.packages("shinycssloaders" ) # For the spinning wheel
install.packages("shinyWidgets" ) # for Extra widgets - https://dreamrs.github.io/shinyWidgets/index.html
install.packages("markdown" ) # To display text boxes in md
install.packages("DT" ) # For table display
### Tidyverse
install.packages("dplyr" )
install.packages("tidyr" )
install.packages("stringr" )
install.packages("forcats" )
6 / 9

Installation - MetaPR2 package

Step 3 - Install the following libraries

### graphics
install.packages("ggplot2" )
install.packages("viridis" )
install.packages("patchwork" )
install.packages("treemapify" )
### maps
install.packages("leaflet" )
install.packages("leaflet.minicharts" ) # To do nice pie charts
### Misc
install.packages("rio" )
### Bioinformatics
if (!requireNamespace("BiocManager", quietly = TRUE))
install.packages("BiocManager")
BiocManager::install("Biobase")
BiocManager::install("Biostrings")
BiocManager::install("phyloseq")
7 / 9

Installation - MetaPR2 package

Step 4 - Launch the metaPR2 shiny server

Run the following line from R studio

install.packages("pkgload")
pkgload::load_all(".")
metapr2App()
8 / 9

Installation - MetaPR2 package

Stop the Shiny application

  • Close the browser window

OR

  • Hit the stop button at the top right of the bottom left window

In case Shiny application crashes

  • Hit the stop button at the top right of the bottom left window
  • Relaunch metapr2App()
9 / 9
Paused

Help

Keyboard shortcuts

, , Pg Up, k Go to previous slide
, , Pg Dn, Space, j Go to next slide
Home Go to first slide
End Go to last slide
Number + Return Go to specific slide
b / m / f Toggle blackout / mirrored / fullscreen mode
c Clone slideshow
p Toggle presenter mode
t Restart the presentation timer
?, h Toggle this help
Esc Back to slideshow