1 - How to install R and RStudio
1 How to use R & Rstudio - installation and cloud
Objectives:
1. Learn about R and RStudio
2. Understand the steps for installation on a computer
2. Access RStudio through the cloud
There are two alternative environments for using R (program) and Rstudio (user interface): installing on your computer or through the cloud. There are few differences between the two ways of working, but the fundamental difference is that installation allows you to use the programs offline, without the need for an internet connection, while with the cloud, well, you already know. On the other hand, with the cloud version, it is not necessary to install either R or RStudio, while with the installed version there are a few steps to do this, described below.
However, you can use the cloud version throughout the Course, without having to worry about installing
R
or RStudio.
2 Installing R and RStudio on your computer
You need to follow a few steps to install R & RStudio on your computer. In practice, you download both programs and install them as you would any other program, whether for Windows, Linux, or Mac. Follow these steps:
Go to the Rstudio website and download the R program.
Install the program with the default options.
On the same website, RStudio, look a little further down for the installer that is most appropriate for your operating system.
Download the file and install it like any other program.
Open the RStudio program, whose interface will look similar to the one below.
3 Accessing R & Rstudio
through the cloud
This is a simple option that does not require any installation. The interface is practically the same as the computer installation. Among some advantages, the speed is usually higher for running and installing packages, since the server is already in the cloud. But because it is online, it requires an initial registration with a login and password. Follow these steps:
- Access the RStudio Cloud.
Sign up or log in with Google (simpler).
The window should look like the one below, although without the projects listed.
- Now for the interesting part. Click on New Project and select New Rstudio Project.
- The final image will be very similar to the one shown by the installed version, see:
Done! You can use either method to access the proposed activities. Below are some quick actions and commands for working with the Rstudio interface and R. However, these are only for creating, executing, and modifying some scripts created for interactivity through animation, simulation, and cartographic visualization.
Let’s get started!