Episode

Snakes in a Grid: Python in Excel

with Sarah Kaiser

Spreadsheets are one of the most common ways to share data, and thankfully Python has lots of tools to help! In this tutorial, we will cover some helpful packages like openpyxl and pandas that make working with spreadsheets in Python a breeze. We will also approach the task from the other direction and explore how you can use Python directly in a spreadsheet in Excel to analyze and visualize your data. The session will include practical exercises where attendees will learn how to load, manipulate, and export spreadsheet data using Python. By the end of this tutorial, participants will be equipped with the skills to efficiently handle spreadsheet tasks in Python as well as leverage Excel to run and share Python code directly in a spreadsheet. By the end of this tutorial, participants will be equipped with the skills to efficiently handle spreadsheet tasks in Python as well as leverage Excel to run and share Python code directly in a spreadsheet.

Chapters

  • 00:00 - Intro: Python in Excel Overview
  • 00:14 - Why Use Python Instead of VBA
  • 01:15 - Security Benefits of Cloud Execution
  • 02:00 - How Python Runs in Excel via Anaconda
  • 03:23 - Excel Module and Jupyter Kernel Explained
  • 04:27 - Data Type Handling in Python Cells
  • 05:02 - Speaker Intro: Dr. Sarah Kaiser
  • 05:49 - Collaboration Benefits for Data Sharing
  • 06:31 - Copilot and Advanced Analysis Mode
  • 06:49 - Demo: Getting Started with Python in Excel
  • 07:42 - Writing and Running Python Cells
  • 08:57 - Switching Between Python and Excel Outputs
  • 10:07 - Python and Excel Formula Interoperability
  • 11:01 - Output Type: Python Object vs Excel Value
  • 11:59 - Using the Formulas Tab for Python Tools
  • 12:27 - Restarting Kernel and Runtime Options
  • 13:01 - Jupyter Notebook Editor in Excel
  • 13:57 - Initialization Script and Custom Imports
  • 14:47 - Execution Order and Layout Tips
  • 15:26 - Offline Options with PyScript
  • 16:14 - Viewing and Navigating Python Cells
  • 16:54 - Loading Data into Python from Excel
  • 17:28 - Why Use Python: ML and Visualization
  • 18:44 - Demo: Advanced Plotting with Matplotlib
  • 19:48 - Creating Dashboards with Python in Excel
  • 20:21 - QandA and Final Resources

Developer
Python

Have feedback? Submit an issue here.