forked from bcaffo/courses
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.Rmd
64 lines (45 loc) · 2.54 KB
/
index.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
---
title : Installing Rtools
subtitle :
author : Jeffrey Leek, Assistant Professor of Biostatistics
job : Johns Hopkins Bloomberg School of Public Health
logo : bloomberg_shield.png
framework : io2012 # {io2012, html5slides, shower, dzslides, ...}
highlighter : highlight.js # {highlight.js, prettify, highlight}
hitheme : zenburn #
url:
lib: ../../libraries
assets: ../../assets
widgets : [mathjax] # {mathjax, quiz, bootstrap}
mode : selfcontained # {standalone, draft}
---
## What is Rtools?
* A collection of tools necessary for building R packages in Windows
* Available for download at [https://cran.r-project.org/bin/windows/Rtools/](https://cran.r-project.org/bin/windows/Rtools/)
<img class=center src=../../assets/img/Rtools/Rtools1.png height='400'/>
---
## Download Rtools
* Select the .exe download link from the table that corresponds to your version of R
* Note: If you're not sure what version of R you have, open or restart R and it's the first thing that comes up in the console
* If you have the most recent version of R, you should select the most recent Rtools download (at the top of the chart)
* Once the download completes, open the .exe file to begin the installation
---
## Install Rtools
* Unless you really know what you are doing, you should just go with the default selections at each step of the installation
* There are only two exceptions worth noting:
* If you already have Cygwin installed on your machine, you should follow the instructions given during installation (and linked to here: [https://cran.r-project.org/bin/windows/Rtools/Rtools.txt](https://cran.r-project.org/bin/windows/Rtools/Rtools.txt))
* _IMPORTANT: You should make sure that the box is checked to have the installer edit your PATH (see below)._
<img class=center src=../../assets/img/Rtools/Rtools8.png height='200'/>
---
## Install devtools
* Once the Rtools installation completes, open RStudio
* Install the devtools R package if you have not previously done so
* If you aren't sure, enter ```find.package("devtools")``` in the console
* To install devtools, use ```install.packages("devtools")```
<img class=center src=../../assets/img/Rtools/devtools1.png height='350'/>
---
## Verify Rtools installation
* After devtools is done installing, load it using ```library(devtools)```
* Then type ```find_rtools()``` as shown below
* This should return ```TRUE``` in the console if your Rtools installation worked properly
<img class=center src=../../assets/img/Rtools/devtools4.png height='350'/>