Course Setup
To complete the exercises for this course, you should install JupyterLab on your computer and download the appropriate Jupyter Notebook.
What are JupyterLab and Jupyter Notebooks?
- JupyterLab is a flexible, web-based programming interface that allows students to run Jupyter Notebooks.
- Jupyter Notebooks are files that allow you to combine text elements with coding cells, so that you can use them ike an interactive textbook. The notebooks we use will be keyed to the videos in each lesson. In each case, you have two options: a "working notebook," which leaves certain coding cells blank so that you can follow along with the videos and enter code yourself, and a "master notebook," essentially a cheat sheet that makes every line of code explicit. We strongly recommend you use the working notebooks. The working notebooks occasionally include blank "sandbox" cells that you can use to complete the practice problems and experiment with coding.
Step 1: Install Anaconda and JupyterLab
There are several different ways to install and manage your Python installation. We recommend using Anaconda, a Python distribution and package manager optimized for data science. Anaconda includes a recent version of Python (3.7 as of Jan 2020) and pre-installs many useful packages, including JupyterLab, so you’re able to get to work right away.
- Installation instructions for all operating instructions are available in the Anaconda Documentation.
Step 2: Download Course Materials
The Jupyter Notebooks required for the exercises in this course can be found at the start of each lesson. In addition, you can download the entire course repository all at once if you'd like to avoid future downloads. As a warning, this repository is large: about 1.5 GB. Depending on your internet connection the files may take quite some time to download, and you may encounter bandwidth limitations if you are operating from a wifi hotspot.
Make sure the Notebook you plan to use is contained in your working directory for JupyterLab. For information on how to open Jupyter Notebooks, refer to the Working with Files section of the JupyterLab documentation.
Step 3: Launch JupyterLab
There are two different ways to launch JupyterLab.
-
We typically prefer to launch JupyterLab from the terminal or command line. You can do this navigating to the directory your files are in (or a parent directory, but not a subdirectory) and then running the command:
jupyter lab
-
You can also use Anaconda Navigator, a GUI application which allows you to run conda packages and programs without using the command line. JupyterLab is available on the main menu.
In either case, JupyterLab will open in a new tab in your default browser. If you experience difficulty, follow the instructions in this installation guide.
ALTERNATE: Use a Jupyter Notebook HTML file and the command line
- You can also use the HTML export of the Jupyter Notebooks and run the code in command line.
- New to coding? For more information on how to run Python from the command line, please refer to the Beginner's Guide to Python.