/table-of-contents

Python Programming 21-22 - Table of contents

Python Programming - Table of contents

Week Videos Tutorial sheet Workshop task
Week 1: Getting started with Python
  • Introduction: Python and Jupyter
  • Variables and objects
  • Basic object types: int, float, str, bool
  1. "Python Programming"?...
  2. How to get the Week 1 tutorial sheet
  3. Python basics: print(), variables, and objects
Tutorial sheet Pair programming
Week 2: Lists, loops, and functions
  • Type-casting and duck-typing
  • Containers: lists, ranges
  • for loops
  • Writing your own functions
  1. Lists, loops, and functions
Code available here
Tutorial sheet Fun with sequences
Week 3: Conditional statements, more loops, and code review
  • Conditional statements: if-elif-else
  • Nested loops and while loops
  • Code review and debugging essentials
  1. Conditional statements, while loops, and error traces
Code available here
Tutorial sheet Code review
Week 4: Numpy, plotting, and reading/writing text files
  • Namespaces and scope
  • Numpy arrays, linear algebra and complex numbers
  • Plotting with matplotlib
  • Reading and writing text files
  1. Namespaces, scope, NumPy, and reading/writing a text file
  2. Search and understand documentation
Code available here
Tutorial sheet NumPy, plotting, and input/output to a file
Week 5: Better plots, docstrings, and introduction to SciPy
  • Label and customise plot appearance
  • Writing good docstrings
  • SciPy for statistics and optimisation
  1. Plotting with matplotlib
  2. Docstrings and doctest
  3. Introduction to SciPy
Code available here
Tutorial sheet Sorting and efficiency
Week 6: More containers, comprehensions, and problem-solving methods
  • Tuples
  • Dictionaries
  • Comprehensions
  • The algorithm design process
  • Problem-solving example: the post office problem
  1. List comprehensions, tuples and dictionaries
Code available here
Tutorial sheet Zipf's law
Week 7: Iterators and generators, and introduction to Pandas
  • Iterators
  • Generators
  • pandas dataframes to manipulate data
  1. Introduction to pandas
Code available here
Tutorial sheet API requests: Weather forecast
Week 8: More pandas, Seaborn
  • Dealing with missing data and text data with pandas
  • Fancy visualisations with seaborn
No videos this week Tutorial sheet Getting started with Project 2
Week 9: More pandas, Seaborn
  • More on groupby
  • Pivot tables
  • Melting dataframes to convert to long format
  1. pandas 1: Grouping dataframes
  2. pandas 2: Reshaping dataframes
  3. pandas 3 + seaborn: Visualising data in "long" form
  4. Edinburgh bike data: Average duration and distance
  5. Edinburgh bike data: Most common starting station
Code available here
No tutorial sheet No workshop task
Week 10: Object-oriented programming
  • Classes and objects
  • Defining your own classes
  • Attributes and methods
  • Special methods and operator overloading
  • Inheritance
  1. Object-oriented programming
Code available here
Tutorial sheet No workshop task