To get started with R, you need to acquire your own copy. This appendix will show you how to download R as well as RStudio, a software application that makes R easier to use. You'll go from downloading R to opening your first R session.
Last released version for Mac OS X 10.4 (Tiger) was R 2.10.1, last release for Mac OS X 10.5 (Leopard) was R 2.15.3, last release for Mac OS X 10.11 (El Capitan) was R 3.6.3. Other binaries The following binaries are not maintained or supported by R-core and are provided without any guarantee and for convenience only (Mac OS X 10.4.4 or higher. RStudio is a set of integrated tools designed to help you be more productive with R. It includes a console, syntax-highlighting editor that supports direct code execution, and a variety of robust tools for plotting, viewing history, debugging and managing your workspace. R for macOS Developers This is the new home for experimental binaries and documentation related to R for macOS. To learn more about the R software or download released versions, please visit www.r-project.org. All software on this page is strictly experimental and subject to acceptance of the supplied R license agreement and the disclaimer at the end of the page. R.rterm.mac: set to R term's path for Mac OS X. R.rterm.linux: set to R term's path for Linux. R.rpath.lsp: set to R.exe path for Language Server Protocol. R.rterm.option: R command line options (i.e: -vanilla) r.source.encoding: An optional encoding to pass to R when executing the file. R.source.focus: Keeping focus when running (editor.
Apogee one driver download. Both R and RStudio are free and easy to download.
A.1 How to Download and Install R
R is maintained by an international team of developers who make the language available through the web page of The Comprehensive R Archive Network. The top of the web page provides three links for downloading R. Follow the link that describes your operating system: Windows, Mac, or Linux.
R For Mac Install Usb
A.1.1 Windows
To install R on Windows, click the 'Download R for Windows' link. Then click the 'base' link. Next, click the first link at the top of the new page. This link should say something like 'Download R 3.0.3 for Windows,' except the 3.0.3 will be replaced by the most current version of R. The link downloads an installer program, which installs the most up-to-date version of R for Windows. Run this program and step through the installation wizard that appears. The wizard will install R into your program files folders and place a shortcut in your Start menu. Note that you'll need to have all of the appropriate administration privileges to install new software on your machine.
A.1.2 Mac
To install R on a Mac, click the 'Download R for Mac' link. Next, click on the R-3.0.3
package link (or the package link for the most current release of R). An installer will download to guide you through the installation process, which is very easy. The installer lets you customize your installation, but the defaults will be suitable for most users. I've never found a reason to change them. If your computer requires a password before installing new progams, you'll need it here.
Binaries Versus Source
R can be installed from precompiled binaries or built from source on any operating system. For Windows and Mac machines, installing R from binaries is extremely easy. The binary comes preloaded in its own installer. Although you can build R from source on these platforms, the process is much more complicated and won't provide much benefit for most users. For Linux systems, the opposite is true. Precompiled binaries can be found for some systems, but it is much more common to build R from source files when installing on Linux. The download pages on CRAN's website provide information about building R from source for the Windows, Mac, and Linux platforms.A.1.3 Linux
R comes preinstalled on many Linux systems, but you'll want the newest version of R if yours is out of date. The CRAN website provides files to build R from source on Debian, Redhat, SUSE, and Ubuntu systems under the link 'Download R for Linux.' Click the link and then follow the directory trail to the version of Linux you wish to install on. The exact installation procedure will vary depending on the Linux system you use. CRAN guides the process by grouping each set of source files with documentation or README files that explain how to install on your system.
Install Rstudio Mac
32-bit Versus 64-bit
Apogee one driver download. Both R and RStudio are free and easy to download.
A.1 How to Download and Install R
R is maintained by an international team of developers who make the language available through the web page of The Comprehensive R Archive Network. The top of the web page provides three links for downloading R. Follow the link that describes your operating system: Windows, Mac, or Linux.
R For Mac Install Usb
A.1.1 Windows
To install R on Windows, click the 'Download R for Windows' link. Then click the 'base' link. Next, click the first link at the top of the new page. This link should say something like 'Download R 3.0.3 for Windows,' except the 3.0.3 will be replaced by the most current version of R. The link downloads an installer program, which installs the most up-to-date version of R for Windows. Run this program and step through the installation wizard that appears. The wizard will install R into your program files folders and place a shortcut in your Start menu. Note that you'll need to have all of the appropriate administration privileges to install new software on your machine.
A.1.2 Mac
To install R on a Mac, click the 'Download R for Mac' link. Next, click on the R-3.0.3
package link (or the package link for the most current release of R). An installer will download to guide you through the installation process, which is very easy. The installer lets you customize your installation, but the defaults will be suitable for most users. I've never found a reason to change them. If your computer requires a password before installing new progams, you'll need it here.
Binaries Versus Source
R can be installed from precompiled binaries or built from source on any operating system. For Windows and Mac machines, installing R from binaries is extremely easy. The binary comes preloaded in its own installer. Although you can build R from source on these platforms, the process is much more complicated and won't provide much benefit for most users. For Linux systems, the opposite is true. Precompiled binaries can be found for some systems, but it is much more common to build R from source files when installing on Linux. The download pages on CRAN's website provide information about building R from source for the Windows, Mac, and Linux platforms.A.1.3 Linux
R comes preinstalled on many Linux systems, but you'll want the newest version of R if yours is out of date. The CRAN website provides files to build R from source on Debian, Redhat, SUSE, and Ubuntu systems under the link 'Download R for Linux.' Click the link and then follow the directory trail to the version of Linux you wish to install on. The exact installation procedure will vary depending on the Linux system you use. CRAN guides the process by grouping each set of source files with documentation or README files that explain how to install on your system.
Install Rstudio Mac
32-bit Versus 64-bit
R comes in both 32-bit and 64-bit versions. Which should you use? In most cases, it won't matter. Both versions use 32-bit integers, which means they compute numbers to the same numerical precision. The difference occurs in the way each version manages memory. 64-bit R uses 64-bit memory pointers, and 32-bit R uses 32-bit memory pointers. This means 64-bit R has a larger memory space to use (and search through).
As a rule of thumb, 32-bit builds of R are faster than 64-bit builds, though not always. On the other hand, 64-bit builds can handle larger files and data sets with fewer memory management problems. In either version, the maximum allowable vector size tops out at around 2 billion elements. If your operating system doesn't support 64-bit programs, or your RAM is less than 4 GB, 32-bit R is for you. The Windows and Mac installers will automatically install both versions if your system supports 64-bit R.A.2 Using R
R isn't a program that you can open and start using, like Microsoft Word or Internet Explorer. Instead, R is a computer language, like C, C++, or UNIX. You use R by writing commands in the R language and asking your computer to interpret them. In the old days, people ran R code in a UNIX terminal window—as if they were hackers in a movie from the 1980s. Now almost everyone uses R with an application called RStudio, and I recommend that you do, too.
R and UNIX
You can still run R in a UNIX or BASH window by typing the command:
which opens an R interpreter. You can then do your work and close the interpreter by runningq()
when you are finished.A.3 RStudio
RStudio is an application like Microsoft Word—except that instead of helping you write in English, RStudio helps you write in R. I use RStudio throughout the book because it makes using R much easier. Also, the RStudio interface looks the same for Windows, Mac OS, and Linux. That will help me match the book to your personal experience.
You can download RStudio for free. Just click the 'Download RStudio' button and follow the simple instructions that follow. Once you've installed RStudio, you can open it like any other program on your computer—usually by clicking an icon on your desktop.
The R GUIs
Windows and Mac users usually do not program from a terminal window, so the Windows and Mac downloads for R come with a simple program that opens a terminal-like window for you to run R code in. This is what opens when you click the R icon on your Windows or Mac computer. These programs do a little more than the basic terminal window, but not much. You may hear people refer to them as the Windows or Mac R GUIs.When you open RStudio, a window appears with three panes in it, as in Figure A.1. The largest pane is a console window. This is where you'll run your R code and see results. The console window is exactly what you'd see if you ran R from a UNIX console or the Windows or Mac GUIs. Everything else you see is unique to RStudio. Hidden in the other panes are a text editor, a graphics window, a debugger, a file manager, and much more. You'll learn about these panes as they become useful throughout the course of this book.
Do I still need to download R?
Even if you use RStudio, you'll still need to download R to your computer. RStudio helps you use the version of R that lives on your computer, but it doesn't comewith a version of R on its own.A.4 Opening R
Now that you have both R and RStudio on your computer, you can begin using R by opening the RStudio program. Open RStudio just as you would any program, by clicking on its icon or by typing 'RStudio' at the Windows Run prompt.
This is the new home for experimental binaries and documentation related to R for macOS. To learn more about the R software or download released versions, please visit www.r-project.org.All software on this page is strictly experimental and subject to acceptance of the supplied R license agreement and the disclaimer at the end of the page.
Starting with R 4.0.0 alpha we are building R using standard Apple tools (Xcode 11.4) and GNU Fortran 8.2 from fxcoudert and the target is macOS 10.13 (High Sierra). All dependent static libraries are available in the libs-4 directory. Please make sure you remove any modifications to build flags from your home since no custom compilers are used anymore. For more information about alternative OpenMP options (as in older version) see the openmp page of this site.
Index
Nightly builds for macOS
R framework
Build | OS | Date | Status | Download |
---|---|---|---|---|
R-3.6-branch 3.6.3 Patched (2020/04/28, r79367) | el-capitan | Oct 24 23:30 | x86_64: OK (log) Package: OK | R-3.6-branch-el-capitan-sa-x86_64.tar.gz (67Mb) R-3.6-branch-el-capitan-signed.pkg (77Mb, installer incl. GUI) |
R-4.0-branch 4.0.3 Patched (2020/10/23, r79367) | high-sierra | Oct 24 21:41 | x86_64: OK (log) Package: OK | R-4.0-branch.tar.gz (73Mb) R-4.0-branch.pkg (85Mb, installer incl. GUI) |
R-devel 4.1.0 Under development (unstable) (2020/10/24, r79367) | high-sierra | Oct 24 21:52 | x86_64: OK (log) Package: OK | R-devel.tar.gz (73Mb) R-devel.pkg (85Mb, installer incl. GUI) |
The installer image (*.pkg) is packaged exactly the same way as the CRAN release of R (including the GUI) and it will update your R version (unless you use pkgutil - see instructions during installation and/or the 'Multiple versions'section of the R Installation and Administration manual).
Best linux for mac. Alternatively, you can use the tar-ball (*.tar.gz) in the table above. The tar-ball must be unpacked in the root directory using:
$ tar fvxz R*.tar.gz -C /
NOTE: The tar-ball does not contain the GUI (see below for a separate download).
NOTE: The installer includes Tcl/Tk package which will install in /usr/local. It is optional (only needed for the tcltk R package) and can be unchecked at installation time.
If you see any issues with the builds, please contact Simon Urbanek (the macOS maintainer of R) or report on the R-SIG-Mac mailing list.
Mac OS X GUI
Version | Build | Download |
---|---|---|
Mac OS X GUI rev. 7782 for R 3.6.x | el-capitan-Debug.dmg | R-GUI-7782-3.6-el-capitan-Debug.dmg |
Mac OS X GUI rev. 7782 for R 3.6.x | el-capitan-Release.dmg | R-GUI-7782-3.6-el-capitan-Release.dmg |
Mac OS X GUI rev. 7894 for R 4.0.x | high-sierra-Debug.dmg | R-GUI-7894-4.0-high-sierra-Debug.dmg |
Mac OS X GUI rev. 7894 for R 4.0.x | high-sierra-Release.dmg | R-GUI-7894-4.0-high-sierra-Release.dmg |
Mac OS X GUI rev. 7894 for R 4.1.x | high-sierra-Debug.dmg | R-GUI-7894-4.1-high-sierra-Debug.dmg |
Mac OS X GUI rev. 7894 for R 4.1.x | high-sierra-Release.dmg | R-GUI-7894-4.1-high-sierra-Release.dmg |
To install, open the image and drag the R icon to your Applications folder. Alternatively the GUI can be run directly off that image without copying if you just want to test it. Build configurations with '64' suffix are 64-bit builds, all others are 32-bit (except for Debug). If you want to use both, rename one of them or place them in different directories.
Tools
In order to compile R and R packages you will need Xcode Developer Tools and a Fortran compiler. For details and download, please read the Tools page. The R 4.0.0 and higer binaries are built using Xcode 11.4.Experimental binary packages
This site no longer hosts experimental packages. It is now the master repository for released R package binaries. If you have issues with other mirrors, try using https://mac.r-project.org/ as your mirror as it is updated first.Legacy R
The current build supports only macOS X 10.13 (High Sierra) or higher. Older versions of macOS are not supported in binary form, but R can be compiled from sources for such legacy OS versions. Last released version for Mac OS X 10.4 (Tiger) was R 2.10.1, last release for Mac OS X 10.5 (Leopard) was R 2.15.3, last release for Mac OS X 10.11 (El Capitan) was R 3.6.3.Other binaries
The following binaries are not maintained or supported by R-core and are provided without any guarantee and for convenience only (Mac OS X 10.4.4 or higher required). They match the binaries used on the CRAN binary build machine and thus are recommended for use with CRAN R package binaries.Download R Studio
- GTK+ 2.24.17 framework - 64-bit build of GTK+ 2.24.17, necessary for binary R packages that use GTK+ version 2 (such as RGtk2+). R 3.0.0 and higher, Snow Leopard build
Download: GTK_2.24.17-X11.pkg (ca. 41MB) - GTK+ 2.18.5 framework - universal build of GTK+ 2.18.5, necessary for binary R packages that use GTK+ version 2 (such as RGtk2+). R 2.10.0 - 2.15.3, Leopard build
Download: GTK_2.18.5-X11.pkg (ca. 58MB) - RSwitch - a small GUI that allows you to switch between R versions quickly (if you have multiple versions of R framework installed).
Download: RSwitch-1.2.dmg (ca 67kB, universal, updated 2011/03/24 to support R 2.13.0 and up)
Sources: RSwitch-1.2.tar.gz (Xcode project and sources)NOTE: Bob Rudis is maintaining a new version of a tool which has RSwitch functionality and more - see 3rd party RSwitch replacement (NOT related to R-Foundation or CRAN!).
R For Mac Install Hp
More external libraries for R 4.0.0 and higher can be found in the /libs-4/ directory. For older versions see the /libs/ directory.