Install R and RStudio

These are the two pieces everything else sits on: R (the engine that does the statistics) and RStudio (the friendlier window you drive it from). Both are free. Install R first, then RStudio on top of it.

You only do this once per computer. If you need to set up a second machine later, this page is the one to come back to.

From the video — download R from CRAN at https://cran.r-project.org, and RStudio Desktop from https://docs.posit.co/ide/user/#rstudio-ide-oss-downloads. Both are walked through in the written steps just below.

NoteSeeing security warnings?

A blue “Windows protected your PC” box, or a prompt about an unrecognized publisher, is normal for brand-new software — click More info, then Run anyway. Launch the downloaded installer from wherever you saved it (usually your Downloads folder) in File Explorer rather than from the browser’s download list: on some university- or employer-managed computers, the browser route can show the blue box with no “More info” link and no way past it, while the Downloads-folder method works on almost every computer. If the box still offers no way through even from there, the block has been set centrally by whoever manages the machine — clearing it is a quick job for your IT department, often a single phone call. The Troubleshooting page walks through each box, and has a short note you can pass to IT.

A work-, university-, or lab-managed computer may not let you install software at all — separate from any security warning, the installer can ask for an administrator password you don’t have, or stop with a message about needing administrator rights. That’s a restriction set by whoever manages the machine, not something you did wrong. Your IT department may be able to install both R and RStudio for you — usually a quick request, where their policies allow — and the Troubleshooting page’s “On a work or managed computer” note lays out the options and includes a short summary you can hand them.

Install R

Go to CRAN — the official archive of R, at https://cran.r-project.org — choose the download for your system (Windows, Mac, or Linux), and run the installer with its default settings. That’s it; you won’t open R directly — RStudio will.

On a Mac, one extra choice matters. The Mac download page offers two installers — one for Apple silicon Macs (the newer M1/M2/M3/M4 chips) and one for older Intel Macs — and you want the one that matches your computer. To check which you have, open the Apple menu (top-left of the screen) and choose About This Mac: a line reading Chip: Apple M… means Apple silicon, while Processor: …Intel… means Intel. Pick the matching installer — its filename ends in arm64 for Apple silicon and x86_64 for Intel. A newer Mac will run the Intel version through Apple’s built-in translation, so grabbing the wrong one isn’t a disaster — but the matching build runs faster and avoids a class of confusing errors that can show up later when you install packages. (Windows has a single installer, so there’s no equivalent choice to make there.)

Install RStudio

Download RStudio Desktop from https://docs.posit.co/ide/user/#rstudio-ide-oss-downloads and install it. (Install R first; RStudio needs it.) On a Mac, the download is a disk image (.dmg): open it, then drag the RStudio icon into your Applications folder. From now on, RStudio is the program you open to work.

The download page also mentions paid products — those are enterprise tools aimed at large organizations, not something you’re missing out on. The free RStudio Desktop is the full program, and it’s the one you’ll open every time you work.

RStudio’s own getting-started guide

You may come across RStudio’s own Get Started guide while poking around. It’s well made, but it’s built around a different set of tools — the tidyverse family of packages (especially ggplot2 for graphs) — rather than jstats, so the commands it teaches aren’t the ones these guides use. It also describes the RStudio window as showing four panes the moment you open it; in practice you’ll see three at first, with the fourth (the top-left editor) appearing once you open a script or view a dataset — which is how the next page describes it, to match what you’ll actually see.

It overlaps a good deal with our own orientation but follows a different path, so for the jstats route the simplest thing is to skip it and keep going here. The next page is that orientation — a quick tour of RStudio (the panes, the console, and how your dataset looks once it’s loaded) — before you add the jstats package itself.