Using Python in Excel
This course is designed to take excel users to the next level by enabling python programming in Excel. Python is an important piece of Microsoft’s future in the cloud, being one of the essential languages for services and teams to support, as well as the most popular choice for the rapidly growing field of data science and analytics both inside and outside of the company.
Over the last ten years, the change has been dramatic. Many Microsoft products now include Python support, and some of the newest only support Python. Therefore if you want to have a future with Microsoft products, python programming is an absolute must!
Learning Outcome
The possible learning outcome of this course is:
- Learn Python from scratch
- Learn xlwings library
- Write and use Dynamic Arrays with xlwings
- Ability to write Excel tools with Python instead of VBA
- Replace VBA macros with clean and powerful Python code
- Call your python code directly from within Excel
- Create powerful Dashboard Apps with Excel (frontend) and Python (backend)
- Write UDFs (user defined functions) and use Numpy, Pandas and Machine Learning Libraries directly in Excel
- Excel task automation with python
- Load data from Web APIs directly into Excel
Prerequisites
- Basic excel usage experience
- Understanding of windows’ file structure
- Windows 10 or higher
- Full installation of MS Excel
- Full admin access in windows (in order to install different python libraries and environments)
- Internet access.
- Webcam (for OLL)
- Basic high-school mathematics
- Willingness to learn
Course Outline
This is a HIGH INTENSITY three-day course.
- Python Basics
- Introduction
- Brief History of Python
- Python Versions
- Installing Python
- IDEs
- Environment Variables
- Python Documentation
- Hello world with python
- Modes of Programming
- Variables and collections
- Numbers
- Python Lists
- Python Tuples
- Python Dictionaries
- Python Sets
- Copying
- Python Strings
- String formatting
- Regular Expressions
- Operations
- Arithmetic Operators
- Comparison (Relational) Operators
- Assignment Operators
- Logical Operators
- Membership Operators
- Operators Precedence
- Decisions and Loops
- The if Statement
- The if else Statement
- For Loop
- While Loop
- Break And Continue
- Functions
- Defining Your Own Functions
- Parameters
- Function Documentation
- Passing Collections to a Function
- Variable Number of Arguments
- Scope
- Map
- Filter
- Lambda
- Introduction
- Matplotlib, Numpy, Pandas, Seaborn
- Introduction to Pandas
- Series
- DataFrames
- Missing Data
- Group By with Pandas
- Merging, Joining, and Concatenating DataFrames
- Pandas Common Operations
- Data Input and Output
- Introduction to Visualization in Python
- Matplotlib Basics
- Matplotlib Introduction
- Line Plots
- Scatter Plots
- Seaborn Visualizations
- Pandas Visualization Overview
- Pandas Time Series Visualization
- Xlwings
- How to connect to an Excel Workbook
- How to read and write single Values
- How to assign a name
- How to write Excel Functions with Python
- Range Shortcuts
- One-dimensional Data Structures
- How to write Values vertically
- Rows and Columns
- How to read two-dimensional Data Structures
- Advanced Reading with expand
- How to write two-dimensional Data Structures
- Range Indexing and Slicing
- Efficiency
- Integration Essentials
- Running Python Scripts with "Run main"
- VBA Macros essentials
- Running Python Scripts with "RunPython"
- Run main vs RunPython
- Excursus
- Visualizations
- How to write a Matplotlib Plot into Excel
- How to update the Plot
- How to change Size and Position
- How write a Seaborn Plot into Excel
- How to create Excel Charts with Python
- User Defined Functions
- Preparations and your first UDF
- How to change the Name and Location of the Python Module
- Troubleshooting (UDF)
- UDFs - Behind the Scenes
- More complex UDFs and the @xw.arg Decorator
- How to create Numpy UDFs
- UDFs and Array Formulas
- How to create Dynamic Arrays with xlwings UDFs
- How to create Pandas UDFs
- How to add Docstrings
- Use case and hands-on
- Case-study
- Assessment
Practical, connected learning
My wider training approach brings hands-on implementation and systems thinking together, connecting technology with real operational needs.