library(eve102) knitr::opts_chunk$set(prompt=FALSE, comment="", fig.width=6, fig.height=6)
R is a programming language designed for statistical computing. It allows you to do incredibly powerful data manipulation, fit statistical models, and visualize data. R has grown incredibly popular in recent years (e.g., see this New York Times articles on R), and is the foundation of most of modern data science. We'll use R in this course, and while at times it may be tricky (learning new programming languages is always tricky), it's worth the effort as knowing R is a very marketable skill. We'll cover the basics here, but other excellent references are:
First, we need to install R, RStudio, and a few R packages. Follow these steps:
Download R and Install R. R is available from the "Comprehensive R Archive Network" (CRAN): https://cran.cnr.berkeley.edu/. Download the version for your operating system using this link. Install R by double clicking the installer you've downloaded in the previous step and follow the instructions. CRAN is also how you install packages that extend R's functionality (more on this later).
Download and install RStudio. RStudio is a program that makes interacting with and developing code in R much easier. Download RStudio Desktop from their website: https://www.rstudio.com/products/rstudio/download3/. Double click the RStudio installer and follow the installation instructions.
Open RStudio and try entering:
```{R, eval=FALSE} print("Welcome to EVE102!")
in the window labeled "Console". It should look something like this (but your exact session will be different): <img src="images/rstudio.png" style="width: 600px;"/> 3. Next, we need to install a few R packages from CRAN. R packages are contributed software that extends the functionality of R. We will first install `devtools`, as this allows us to install the `eve102` course package from GitHub (GitHub is a website for sharing code and collaboratively working on projects). Then, we will load the `devtools` package with the `library()` function, and then install the `eve102` package. Note that if you are prompted to answer any questions during installation, answer the affirmative, i.e. 'y' or yes. Run the following (e.g. copy and paste): ```{R, eval=FALSE} install.packages('devtools') library(devtools) install_github('vsbuffalo/eve102', build_vignettes=TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.