This is the content of a set of Python courses. For more details see the course outlines
Getting started lesson and exercise
Data types lesson and exercise
Control flow lesson and exercise
Strings (and methods, and indexing / slicing) lesson and exercise
Data Structures
List comprehensions lesson and exercise
We may need to install a package.
Using the requests package
A very brief look at some common modules and packages: datetime; math and statistics
Consolidation of foundation content day2_starter_exercise. This revises strings, lists, conditional flow, and has a final brain teaser exercise
Writing functions lesson, exercise and another exercise
OpenAI demo connects to ChatGPT to have a conversation
Read and write Excel files: a simple starter example and a more complete example that reads several tables from an Excel file into pandas DataFrames, merges the the tables, summarises the data, creates a chart then exports the summarised data in both CSV and Excel file formats
Introduction to data analysis with pandas - tutorial
Introduction to data visualisation with seaborn - tutorial
Retrieving data from SQL - demo
Retrieve Data from an API / web pages the requests package
- Police Street Crime Exercise retrieves recent crime incidents in a local area
- COVID Cases examples using requests and then the uk_covid19 SDK
The advanced course focusses on data analysis with the numpy, pandas and seaborn packages. The numpy package underpins many data analysis packages (including pandas), and AI packages.
pandas is the library for data analysis in Python. The course covers it in detail.
- lesson 1 and exercise 1
- lesson 2 and exercise 2
- lesson 3 and exercise 3
- lesson 4 and exercise 4
- titanic exercise
- fx rates example (time-series data)
- league table example
- COVID cases example
Visualise data with the seaborn package.
- diamonds exercise
- iris exercise
- MPG example
- survey example
- restaurant tips example
- titanic passenger example
Functional programming lesson and exercise
Building classes (object-oriented programming) lesson and exercise
If time allows, a very brief look at:
- exceptions,
- type annotations,
- reading or writing files, managing directories with the os and shutil modules
- the re module for regex functionality