Prepare for Plotting and Programming in Python
Thursday, October 29, 2026 and Thursday, November 5, 2026
6:00-9:00 PM Central Time
Bruner Hall, Room 126
No previous Python experience is required. We will use JupyterLab, an interactive environment that allows us to write and run Python code in a web browser. We will launch JupyterLab from Git Bash on Windows or Terminal on macOS and Linux.
Please complete the setup before the first meeting and bring the same laptop to both meetings.
The material for this lesson is drawn from The Carpentries Plotting and Programming in Python lesson.
What to bring
- A Windows, macOS, or Linux laptop
- Your laptop’s charging cable
Complete these steps before the workshop
- Install Miniforge, unless you already have it.
- Create the workshop environment. This installs Python, NumPy, and Matplotlib.
- Download and extract the lesson files. The data for this lesson is taken from the gapminder dataset.
- Check your setup.
- Complete the pre-workshop survey. If you already completed it for this series, you do not need to complete it again.
- Review The Carpentries Code of Conduct.
Install Miniforge
Miniforge will let us install Python and the scientific packages used in the lesson together. This includes the JupyterLab that we will use for this lesson. If you already have Miniforge, skip to Create the workshop environment. You do not need a separate Python installation. On Windows, if you already have Miniforge but have not used it in Git Bash, open Miniforge Prompt, run conda init bash, then close and reopen Git Bash before creating the workshop environment.
If you do not already have Git Bash installed, follow the Windows installation instructions before continuing.
- Open https://conda-forge.org/download/ with your web browser.
- Download the Miniforge for Windows installer
- Double-click on the downloaded file (Something like,
Miniforge3-Windows-x86_64.exe)- If Windows displays a “Windows protected your PC” message, select “More info,” then “Run anyway.”
- Follow through the installer using all of the defaults for installation except make sure to check Add Miniforge3 to my PATH environment variable.
- When installation finishes, open the Start menu and launch Miniforge Prompt.
- In Miniforge Prompt, type
conda init bashand press Enter. Close any open Git Bash windows, then open a new Git Bash window.
- Open https://conda-forge.org/download/ with your web browser.
- Download the appropriate Miniforge installer for macOS
The following steps require using the shell. If you aren't comfortable doing the installation yourself stop here and request help at the workshop. -
Open a terminal window and navigate to the directory where the executable is downloaded
(e.g.,
cd ~/Downloads). -
Type
bash Miniforge3-
and then press Tab to autocomplete the full file name. The name of file you just downloaded should appear. Press Enter (or Return depending on your keyboard). -
Follow the text-only prompts in the terminal. To move through the text, press
Spacebar.
- Type
yesand press Enter (or Return) to approve the license. - Press Enter (or Return) to approve the default location for the files.
- When the installer asks whether to initialize conda for your shell, type
yesand press Enter (or Return) to prepend Miniforge to yourPATH(this makes the Miniforge distribution the default Python).
- Type
- Close the terminal window, then open a new one before continuing.
- Open https://conda-forge.org/download/ with your web browser.
- Download the appropriate Miniforge installer for Linux
The following steps require using the shell. If you aren't comfortable doing the installation yourself stop here and request help at the workshop. -
Open a terminal window and navigate to the directory where the executable is downloaded
(e.g.,
cd ~/Downloads). -
Type
bash Miniforge3-
and then press Tab to autocomplete the full file name. The name of file you just downloaded should appear. Press Enter (or Return depending on your keyboard). -
Follow the text-only prompts in the terminal.
To move through the text, press Spacebar.
- Type
yesand press Enter (or Return) to approve the license. - Press Enter (or Return) to approve the default location for the files.
- When the installer asks whether to initialize conda for your shell, type
yesand press Enter (or Return) to prepend Miniforge to yourPATH(this makes the Miniforge distribution the default Python).
- Type
- Close the terminal window, then open a new one before continuing.
Create the workshop environment
A Python environment keeps the version of Python and the packages for this workshop together. The file below tells Miniforge which packages to install, including NumPy and Matplotlib. You create this environment only once; you activate it each time you return to the workshop.
-
Right-click the
workshop environment file
and select Save link as. Save it in Downloads with the name
carpentries_environment.yml. Check that your browser has not added.txtto the filename. - Open Git Bash. This is where you will type the following commands.
-
Navigate to the folder where you saved the file. If it is in your usual
Downloads folder, enter:
If your Downloads folder is redirected through OneDrive, navigate to its actual location instead, as you did in the earlier workshops.cd ~/Downloads -
Check that Git Bash can see the file:
You should see the filename printed. If you see “No such file or directory,” check the folder and filename before continuing.ls carpentries_environment.yml -
Create the workshop environment:
Miniforge will read the file and install Python, NumPy, Matplotlib, and the other packages listed in it. This may take several minutes.conda env create -f carpentries_environment.yml -
When the command finishes and you can type again, activate your new environment by entering:
You should seeconda activate carpentries(carpentries)near the beginning of the Git Bash prompt.
-
Right-click the workshop
environment file
and select Save Link As or
Download Linked File As. Save it in Downloads as
carpentries_environment.yml. - Open Terminal. You can find it using Spotlight search or in Applications → Utilities. Click in the Terminal window to type commands.
-
If you saved the file in Downloads, type this command and press
Return:
Miniforge will read the file and install the workshop packages. This may take several minutes.conda env create -f ~/Downloads/carpentries_environment.yml -
When the command finishes and you can type again, activate your new environment by entering:
You should now seeconda activate carpentries(carpentries)near the beginning of the prompt.
-
Right-click the workshop
environment file
and select Save Link As. Save it in Downloads as
carpentries_environment.yml. - Open your computer's Terminal application. Click in the Terminal window to type commands.
-
If you saved the file in Downloads, type this command and press
Enter:
Miniforge will read the file and install the workshop packages. This may take several minutes.conda env create -f ~/Downloads/carpentries_environment.yml -
When the command finishes and you can type again, activate your new environment by entering:
You should now seeconda activate carpentries(carpentries)near the beginning of the prompt.
For the second workshop meeting: Open Git Bash on Windows,
or Terminal on macOS or Linux, and run
conda activate carpentries. You do not need to download the
environment file or create the environment again.
Download the lesson files
- Download the lesson ZIP file.
- Create a folder named
python-novice-gapminder-dataon your Desktop. - Move the downloaded ZIP file into
python-novice-gapminder-data. - Extract the ZIP file. Some computers will create a folder named
python-novice-gapminder-data. If that happens, open that folder and move thedatafolder inside it up into the firstpython-novice-gapminder-datafolder. - Check the result: opening
python-novice-gapminder-dataon yourDesktopshould showdatadirectly inside it. Opendataand confirm that it containsgapminder_all.csv.
If your Desktop is redirected through OneDrive, use the Desktop location you have used in the previous workshops.
Check your setup
Open Git Bash on Windows or Terminal on macOS or Linux. Activate the workshop environment:
conda activate carpentries
You should see (carpentries) near the beginning of the prompt. Now check that Python can load the packages used in the lesson:
python -c "import numpy, pandas, matplotlib.pyplot, jupyterlab; print('Python setup is ready')"
If you see Python setup is ready without an error, the software is ready.
Check that your JupyterLab is ready:
jupyter lab
This should open a browser tab that looks something like this:
Finally, confirm that your Desktop python-novice-gapminder-data folder contains data directly inside it, and that data contains gapminder_all.csv.
During the workshop, we will start the JupyterLab instance with jupyter lab in Git Bash or Terminal from the python-novice-gapminder-data directory.