
Installation of R and RStudio
What is R and RStudio?
R, or RStudio is a statistical software programming package that allows the user to carry out different types of statistical analysis. It can also be used as a GIS software to perform various kinds of spatial analysis as you will see throughout the course of GEOG0114. In the same vein, you can use it for data managing and geo-processing (i.e., importing different types of spatial formats for manipulation beforehand for spatial analysis). There are two versions:
The famous icon on the left is the version for R, and the one on the right is the version for RStudio. Both software packages are the same. The only difference is that RStudio is attractive, intuitive, and more importantly, it is user-friendly than Base R. So, we will be using this version (i.e., RStudio) throughout the course.
Let us talk about downloading RStudio.
Downloading and install R and RStudio on to your laptop
RStudio is an open source software, and today its the go-to software for many researchers - its highly recommended for anyone in the domains of data science, scientific research, and technical communication.
It is easy to access, and easy to download and install. In order for RStudio to work you must first install R. You can follow the steps to download and install the correct version of R and RStudio for your operating system (i.e., Windows or MAC).
Installation for MacOS users
You will need to have the following software installed for R and RStudio to work properly on MAC.
- R (version 4.6.1) and RStudio (version 2026.09.0-174)
- XQuartz (version 2.8.6)
- XCode (version 27.0)
- GNU Fortran (version 12.2)
Installation of R (4.6.1) and RStudio (2026.09.0-174) on MAC:
| OS User type | R (Base) | RStudio Desktop |
|---|---|---|
| MAC (Intel) | R-4.6.1-x86_64.pkg | RStudio-2026.09.0-174.dmg |
| MAC (M1, M2, M3, or M4) | R-4.6.1-arm64.pkg | RStudio-2026.09.0-174.dmg |
- First download the appropriate R (Base) file for the appropriate MacOS.
- Double-click the downloaded file (i.e.,
R-4.6.1-x86_64.pkgorR-4.6.1-arm64.pkg) and follow the steps to complete the installation. - Next, download the
RStudio-2026.09.0-174.dmgto install RStudio. - Double-click the downloaded file (i.e.,
RStudio-2026.09.0-174.dmg) and then drag and drop the RStudio icon into the Applications folder to complete the installation.
Installation of XQuartz (2.8.6):
Some functions in R require some of the libraries from XQuartz to function properly on your MAC.
- You can download the latest version of XQuartz (XQuartz-2.8.6.pkg) by clicking on this LINK and complete the installation process by following its steps.
Installation of XCode (27.0):
Some functions in R require external developer tools provided by the XCode application to function properly on your Mac.
- Go to the App Store application and get the XCode app downloaded by clicking on this LINK.
- Once XCode has been downloaded, click the OPEN button to launch the application. You may be prompted to complete the installation of additional components.
- Follow the on-screen instructions and allow XCode to install any required developer tools and components.
- Finally, make sure that you read and accept the XCode licence agreement when prompted. This is an important step, as some R packages and external tools that require C/C++ compilation may not function correctly until the XCode licence has been accepted.
GNU Fortran (version 12.2):
R (Base) and some packages require the GNU Fortran 12.2 compiler in order to function smoothly on your MacOS.
- Download this specific version of GNU Fortran 12.2 (
gfortran-12.2-universal.pkg) by clicking on this LINK and simply complete the installation process by following the steps on your system.
The above four steps should complete the installation process for R and RStudio on MAC.
Installation for Windows users
You will need to have the following software installed for R and RStudio to work properly on Windows 11.
- R (version 4.6.1)
- Rtools45 (version 4.5)
- RStudio (version 2026.09.0-174)
Installation of R (4.6.1) and RStudio RStudio (2026.09.0-174) on Windows:
| OS User type | R (Base) | RStudio Desktop |
|---|---|---|
| Windows | R-4.6.1-win.exe | RStudio-2026.09.0-174.exe |
- Download the file for
R-4.6.1-win.exeattached in the table above. - Double-click the downloaded file (i.e.,
R-4.6.1-win.exe) and follow the steps to complete the installation. - Now, we can download the file (i.e.,
RStudio-2026.09.0-174.exe) for RStudio from the link provided in the above table. - Double-click the downloaded file (i.e.,
RStudio-2026.09.0-174.exe) and follow the steps from the installer to complete the installation.
Installation of Rtools 4.5
For Windows users, after you have completed the installation for R and RStudio, you are required to install the Rtools45 package as it contains some libraries and developer tools for the smooth functioning of R.
- Download the latest version of Rtools45 by clicking on this LINK to initiate the download of the Rtools45 installer.
- Double-click the downloaded rtools45-6768-6492.exe file and follow the steps to complete the installation.
The above two steps should complete the installation process for R and RStudio on Windows.
The installation of all programs on Windows and MacOS are specifically for R (version 4.6.1) and RStudio (version 2026.09.0-174), which are the most up-to-date versions of R and RStudio, respectively, as of writing these instructions on (04/10/2026). If an update gets pushed for R and RStudio, please ensure they are updated. Also, do make sure to check that the supporting programs (i.e., Rtools for Windows, and XQuartz & XCode for Mac) are updated as well.
This concludes the installation section and sets your computer up for the course.