Skip to content

Commit

Permalink
workspace image
Browse files Browse the repository at this point in the history
  • Loading branch information
siobhanschenk committed Dec 12, 2023
1 parent 001130d commit 460cf92
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
Binary file added content/images/never_save.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 20 additions & 2 deletions content/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,32 @@ parent: Workshop Content
has_toc: false
---

### 1. Install R - the computing software
### 1. Install R - the computing software

Go to <https://mirror.rcg.sfu.ca/mirror/CRAN/> and download the right version for your operating system

![](images/installR.png)

### 2. Install RStudio - the graphical interface that we will be working in today
### 2. Install RStudio - the graphical interface that we will be working in today

Go to <https://posit.co/download/rstudio-desktop/> and scroll to find the right version for your operating system

![](images/install_RStudio.png)

### 3. Format R

Open *tools \> Global Options* and then you will see the pop up below. In the *General* tab, select the "Never" option for Save workspace to .RData on exit.

![](images/never_save.png)

##### Why are we formatting R like this?

The workspace image (what we just set to never save) is en entire history of your R session. Although this seems like a good thing to save on the surface, there are a few reasons to not save the workspace image:

1. It takes up a lot of memory on your computer and makes R start up much slower.

2. Restarting R and re-running the code in a fresh R session as a troubleshooting method now doesn't work.

3. If you send your script (R code) to someone else, they don't have your workspace image, so it's possible the script will not work for them when they run it. This is a consequence of no testing code properly, which follows point 2.

4.

0 comments on commit 460cf92

Please sign in to comment.