Permalink
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
119 lines (84 sloc) 6.31 KB

Install

Preheat the Oven

Download VirtualBox

Virtual Box is the software for a dashboard that allows you to run a small linux computer within your laptop! Find the right package for your OS and install it:

Download Vagrant

Vagrant is a system that allows you to automate a lot of the process involved in configuring and controlling Virtual Box machines on your laptop.

Go to the Vagrant download page to find the installation package for your OS. Download the package and double click it to open it with your package manager (software installer). On Ubuntu, the "Software Center" will launch and you click either the orange "Install" or "Upgrade" button.

While You Wait

If your box downloads quickly, you can skip to the bottom and Get Going

Otherwise you can set up accounts with GitHub, etc while you wait.

Set Up Accounts

  • GitHub
    • Keep track of your projects
      • "Undo" when you make mistakes
      • git checkout answer when you have trouble with a project
    • Your forks of others' projects
    • Give back to the class by sharing your edits, material, links, code
    • Pull Requests to the Hack University projects
  • Join us on Slack
    • We'll use Slack for polls and questions during class
    • You might also enjoy PDXData.Slack.com
  • SignUp for a Twitter account
  • Google Drive or Gmail account

Text Editor

You can survive with an ssh and XWin connection to an editor on the Vagrant Box (virtual machine). But if you'd like a bit higher bandwidth and the "native" feel of your OS, install your favorite text editor on IDE on your laptop. Here are some of the features of the most popular python editors:

  • PyCharm Community Edition
    • integrated git
    • integrated execution of python scripts
    • not as useful for editing other languages
  • Sublime Text 2 Free Edition
    • some basic execution of python scripts
    • powerful regular expressions
    • fast, clean
    • useful plugins like linters for almost all languages
    • easily customizable
    • difficult to install and maintain plugins
  • Atom
    • fast
    • open source
    • backed by GitHub and a favorite of Google developers
    • customizable
    • new, bleeding edge

Version Control

And you probably want a decent "diff" tool to compare text files. I like Meld.

You probably also want git installed locally and have a way of running it from a shell with "readline" (remembers your commands so you don't have to retype them). Git-Bash from GitHub does all this for you. On Linux, you probably already have git installed and you definitely have a decent shell ;)

Windows

If I have to work on Windows, I always install

OSX

Linux

On Linux I can usually get away with using the standard package manager (apt-get on Ubuntu) and pip

sudo -H pip install -r requirements.txt?

Get Going

Once you've installed VirtualBox and Vagrant you can boot up your first Vagrant box. Below I've modified Vagrant's instructions to use Bill McGair's [customized version](https://atlas.hashicorp.com/boxes/search?utf8=%E2%9C%93&sort=&provider=&q=HackOregonDST](http://datasciencetoolbox.org).

You don't want to do this over a slow Cafe WiFi, or on a laptop that is running out of hard drive space. The vagrant up command below has to first download the DataScienceToolbox *.box file, and it's huge (850 MB). If you have an Ethernet jack handy you might plug in before running the vagrant up command...

$ mkdir hackoregon-dst
$ cd hackoregon-dst
$ vagrant init bmcgair/hackoregon-dst
$ vagrant plugin install vagrant-vbguest
$ vagrant up

Follow the rest of the instructions for the Data Science Toolbox to set up ipython notebook to run on Bill's virtualbox you just downloaded and booted. You might also like having the dsftcl bundle installed on your box, if you like using Linux shell to process lots of data quickly.

Pro Tip (optional)

If you'd like others to be able to query your database or run and edit your ipython notebooks on your server running on your laptop, you just need to share the IP address of your Vagrant box with them. And you'll need to ensure that your Vagrant box is configured to use NAT and set up the host machine (your laptop) forward port 8888, 80, and 8000 (or whatever ports you need) through Vagrant (VirtualBox).

Finally

Now you can review the syllabus and start working on some problems.