-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.Rmd
209 lines (148 loc) · 8.04 KB
/
setup.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
---
bibliography: setup_refs.bib
number-sections: false
---
# Data & Setup {.unnumbered}
<!--
Note for Training Developers:
We provide instructions for commonly-used software as commented sections below.
Uncomment the sections relevant for your materials, and add additional instructions where needed (e.g. specific packages used).
Note that we use tabsets to provide instructions for all three major operating systems.
-->
::: {.callout-tip level=2}
## Workshop Attendees
If you are attending one of our workshops, we will provide a training
environment with all of the required software and data. If you want to setup
your own computer to run the analysis demonstrated on this course, you can
follow the instructions below.
:::
## Data
The data used in these materials is provided as a zip file.
Download and unzip the folder to your Desktop to follow along with the materials.
<!-- Note for Training Developers: add the link to 'href' -->
<a href="https://www.dropbox.com/scl/fo/4vscf2xu63xayjssbubn9/h?rlkey=f7imt8zcp0mcsb73gawt4thie&dl=1">
<button class="btn"><i class="fa fa-download"></i> Download</button>
</a>
## Working on your own laptop
If you wish to work on your own laptop during the course and not the training
machines you will need to have the latest stable versions of R, RStudio and
Bioconductor including the packages listed below.
### R and RStudio
This lesson assumes that you have current versions of the following installed on
your computer:
1. The [R software](https://cran.r-project.org/mirrors.html) itself, and
2. [RStudio Desktop](https://www.rstudio.com/products/rstudio/download/#download).
R and RStudio require separate downloads and installations. R itself refers to
the underlying language and computing environment required to write and read
this language. RStudio is a graphical integrated development environment which
essentially makes running R much easier and more interactive.
<!-- ### Quarto -->
<!-- To develop and render the course materials website, you will need to install _Quarto_: -->
<!-- - Download and install [Quarto](https://quarto.org/docs/get-started/) (available for all major OS). -->
<!-- - If you are developing materials using executable `.qmd` documents, it is recommended that you also install the extensions for your favourite IDE (e.g. RStudio, VS Code). -->
<!-- - If you are developing materials using **JupyterLab** or **Jupyter Notebooks**, please install [Jupytext](https://jupytext.readthedocs.io/en/latest/install.html). -->
<!-- - Use the [paired notebook](https://jupytext.readthedocs.io/en/latest/paired-notebooks.html) feature to have synchronised `.ipynb`/`.qmd` files. Only `.qmd` files should be pushed to the repository (`.ipynb` files have been added to `.gitignore`). -->
::: {.tabset group="os"}
#### Windows
Download and install all these using default options:
- [R](https://cran.r-project.org/bin/windows/base/release.html)
- [RTools](https://cran.r-project.org/bin/windows/Rtools/)
- [RStudio](https://www.rstudio.com/products/rstudio/download/#download)
#### Mac OS
Download and install all these using default options:
- [R](https://cran.r-project.org/bin/macosx/)
- [RStudio](https://www.rstudio.com/products/rstudio/download/#download)
#### Linux
- Go to the [R installation](https://cran.r-project.org/bin/linux/) folder and look at the instructions for your distribution.
- Download the [RStudio](https://www.rstudio.com/products/rstudio/download/#download) installer for your distribution and install it using your package manager.
:::
### R package installation
In this workshop we make use of open-source software from the
[R](https://www.r-project.org) [Bioconductor](https://bioconductor.org)
[@Huber2015] project. The [Bioconductor initiative](https://bioconductor.org)
provides [R](https://www.r-project.org) software packages dedicated
to the processing of high-throughput complex biological data. Packages are
open-source, well-documented and benefit from an active community of developers.
Detailed instructions for the installation of Bioconductor packages are
documented on the [Bioconductor Installation page](http://bioconductor.org/install/).
The main packages required for this workshop are installed using the code below.
Additional packages required for downstream statistics and interpretation are
installed as required.
```{r install_packages, eval = FALSE, message = FALSE}
if (!require("BiocManager", quietly = TRUE)) {
install.packages("BiocManager")
}
BiocManager::install(c("QFeatures",
"NormalyzerDE",
"limma",
"factoextra",
"org.Hs.eg.db",
"clusterProfiler",
"enrichplot",
"patchwork",
"tidyverse"))
```
After installation, each package must be loaded before it can be used in the R
session. This is achieved via the `library` function. Here we load all packages
included in this course.
```{r load_packages, message = FALSE, results = "hide", message=FALSE, warning=FALSE}
library("QFeatures")
library("NormalyzerDE")
library("limma")
library("factoextra")
library("org.Hs.eg.db")
library("clusterProfiler")
library("enrichplot")
library("patchwork")
library("tidyverse")
```
<!--
### Conda
Open a terminal and run:
```bash
wget -q -O - https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh
bash Miniconda3-latest-Linux-x86_64.sh -b
rm Miniconda3-latest-Linux-x86_64.sh
conda init
conda config --add channels defaults; conda config --add channels bioconda; conda config --add channels conda-forge; conda config --set channel_priority strict
conda install -y mamba
```
Note: Windows users can use WSL2 (see @wsl).
-->
<!--
### Singularity
::: {.panel-tabset group="os"}
#### Windows
You can use _Singularity_ from the _Windows Subsystem for Linux_ (see @wsl).
Once you setup WSL, you can follow the instructions for Linux.
#### Mac OS
Singularity is [not available for Mac OS](https://docs.sylabs.io/guides/3.0/user-guide/installation.html#install-on-windows-or-mac).
#### Linux
These instructions are for _Ubuntu_ or _Debian_-based distributions[^1].
[^1]: See the [Singularity documentation page](https://docs.sylabs.io/guides/3.0/user-guide/installation.html#install-on-linux) for other distributions.
```bash
sudo apt update && sudo apt upgrade && sudo apt install runc
CODENAME=$(lsb_release -c | sed 's/Codename:\t//')
wget -O singularity.deb https://github.com/sylabs/singularity/releases/download/v3.10.2/singularity-ce_3.10.2-${CODENAME}_amd64.deb
sudo dpkg -i singularity.deb
rm singularity.deb
```
:::
-->
<!--
### Visual Studio Code
::: {.panel-tabset group="os"}
#### Windows
- Go to the [Visual Studio Code download page](https://code.visualstudio.com/Download) and download the installer for your operating system.
Double-click the downloaded file to install the software, accepting all the default options.
- After completing the installation, go to your Windows Menu, search for "Visual Studio Code" and launch the application.
- Go to "_File > Preferences > Settings_", then select "_Text Editor > Files_" on the drop-down menu on the left. Scroll down to the section named "_EOL_" and choose "_\\n_" (this will ensure that the files you edit on Windows are compatible with the Linux operating system).
#### Mac OS
- Go to the [Visual Studio Code download page](https://code.visualstudio.com/Download) and download the installer for Mac.
- Go to the Downloads folder and double-click the file you just downloaded to extract the application. Drag-and-drop the "Visual Studio Code" file to your "Applications" folder.
- You can now open the installed application to check that it was installed successfully (the first time you launch the application you will get a warning that this is an application downloaded from the internet - you can go ahead and click "Open").
#### Linux (Ubuntu)
- Go to the [Visual Studio Code download page](https://code.visualstudio.com/Download) and download the installer for your Linux distribution. Install the package using your system's installer.
:::
-->
# References