Lab 0 - Hello, World and DSC 223!
This lab will set you up for the computing workflow and give you an opportunity to introduce yourselves to each other and the teaching team.
Hello, World!
You may have heard/seen this phrase, Hello, World!
, elsewhere before. It’s usually the first thing you learn in programming – to learn to write a computer program to print this sentence to screen. Things will be different in this course, as it’s not a programming, but a data science course. So, starting today in class, you’ll learn to use a computer program (called R) to work with data.
We need to set you up for success! Let’s first briefly review the components of the computational toolkit for the course:
R: The programming language you’ll learn in this course.
RStudio: The piece of software (a.k.a. the integrated development environment, IDE) you’ll use to write R code in.
R is the name of the programming language itself and RStudio is a convenient interface.
- Quarto: The tool you’ll use to create reproducible computational documents that contain both your narrative (i.e., words in English) and your code (i.e., code in R). Every piece of assignment you hand in will be a Quarto document.
You might be familiar with word processors like MS Word or Google Docs. We will not be using these in this class. Instead, the words you would write in such a document as well as the code will go into a Quarto document, and when you render the document (more on what this means later) you will get a document out that has your words, your code, and the output of that code. Everything in one place, beautifully formatted!
- Git: Version control system.
- GitHub: A web hosting service for the Git version control system that also allows for transparent collaboration between team members.
Git is a version control system (like “Track Changes” features from Microsoft Word but more powerful) and GitHub is the home for your Git-based projects on the internet (like DropBox but much better).
Create a GitHub account (if not done already)
You should have already done this via the intro survey.
Go to https://github.com/ and walk through the steps for creating an account.
Access to R and RStudio
- You will access these by going to http://turing.cornellcollege.edu:8787/ and logging in with your lower case Cornell username and Password abc123. I suggest doing this in a new tab!
This is hosted on a machine on campus which means that no computations are done on your own computer. You will need to be on campus to use this. Bookmark it!
Change your RStudio Password
The first thing I want you to do is change your password so other students cannot get into your account.
- Click Terminal at the top left.
- Type passwd you_username (
- change out your username of course, Cornell username, lower case
- Enter in your current password (abc123)
- It is supposed to be blank. When you type, you are filling it in.
- Enter in a new password. You are welcome to use your Cornell password.
- Enter in new password.
You should only need to do this once. If you forget your password I do have the ability to reset it but you will have to email me and wait :(
Setup your RStudio Account to Speak to Git
In order for you to clone github repositories you need to register your git information with the machine RStudio is running on.
You should only need to do this once!
- You should already have this open from above, but if not, navigate back to RStudio and login.
- Make sure you are still in the Terminal from above as well.
- type git config –global user.name “your_username”
- You are using the exact word user.name but changing “your_username” to be your own. Drop the quotes!
- Notice the dot in user.name
- type git config –global user.email “email_used_for_github_account”
- type your whole email, no quotes. It needs to be the email you used to create your Github account.
- Most of you, this will be your Cornell email.
- Check if it worked: type git config –global –list
- If you scroll down a little you should see your correct Github username and email
Example with my test account:
git config –global user.name stats_test
git config –global user.email stats_test@cornellcollege.edu
git config –global –list
That is it for now! Now you are all prepped and ready to do our first exercise AE 00.