Week 00: Getting started
Welcome to the course Quantitative Methods at the University of Mannheim. In this course we will use the open-source software R
and RStudio. Before we get started with the labs on Thursday, we would like you to install both R
and RStudio on your computer. Here we provide you with detailed instructions to install these programs. If you have any problems getting R
and RStudio running, do not hesitate to drop us an email (Oliver, Viktoriia, or David).
What is R
?
R
is a programming language designed to help you perform statistical analysis, create graphics, and later on write your own statistical software. R
is becoming increasingly popular and knowledge of R
will help you in the job market. R
is probably the most versatile statistical tool out there (and its free and open source so you can literally use it anywhere).
What is RStudio?
RStudio is very good graphical user interface for R
and will be the program which we will use during the lab sessions. In recent years a growing number of features have been added to this graphical user interface, which makes it the preferred choice for learning R
especially among beginners.
What are git and GitHub?
Git is a version control system that makes it easy to track changes and work on code collaboratively. GitHub is a hosting service for git
. You can think of it as a public Dropbox for code but on steroids. With version control, you will build your projects step-by-step, be able to come back to any version of the project, and accompany everything with human readable messages.
As a student, you even get unlimited private repositories which you can use if you don’t feel like sharing your code with the rest of the world (yet). We will use private repositories to distribute code and assignments to you. And you will use it to keep track of your code and collaborate in teams.
With git, writing code for a project will look somewhat like this:
Here is how you set it all up.
How to Install R
- Open your browser and go to https://cran.rstudio.com.
- Download the latest binary distribution for your operating system:
- Windows users: Click on Download R for Windows and then click on base. Click on Download R 4.1.1 for Windows.
- Mac users: Click on Download R for (Mac) OS X and download
R-4.1.1.pkg
.
- Run the installation from the file you just downloaded (
.exe
or.pkg
). - Now that R is installed, you need to download and install RStudio.
How to Install RStudio
- Go to www.rstudio.com and click on the Download button on the top bar.
- Scroll down and click on the Download button for the free RStudio Desktop version.
- Download the latest version (1.4.1717) for your operating system:
- Windows users: Click on the button Download RStudio for Windows. The file should have a
.exe
extension. - Mac users: Click on Download RStudio for (Mac) OS X. You should see a
.dmg
extension.
- Windows users: Click on the button Download RStudio for Windows. The file should have a
- Install it!
How to Get a GitHub account
If you already have an account, please let us know your username as soon as possible.
Otherwise, please follow these steps:
- Go to https://github.com/ and create an account.
- Use this username: qm2021-[ILIAS-login]
- It would be best to use your
@mail.uni-mannheim.de
to sign up.
How to Install git
on Your Computer
- Go to https://git-scm.com/downloads and click on your operating system.
- Follow the instructions and install git.
- When asked about “Adjusting your PATH environment”, make sure to select “Git from the command line and also from 3rd-party software”.
- Open RStudio.
- In the lower left pane click on
Terminal
. - Type
git
and hit Enter. - If you get an overview of the usage of
git
and severalgit
commands, everything worked fine and you are all set for Week 01. - If you don’t see what is described under 6. please email us (Oliver, Viktoriia, or David) or send us a DM in Slack as soon as possible!