Case Studies Teaching Tools

Using Jupyter Notebooks to teach computational literacy

Laptop and pages of an open book

Computational literacy is a key skill that employers are looking for, yet it is often difficult to engage learners in learning to code if they can’t see any practical applications for the exercises they are given.  Programmes such as MATLAB are widely available in the University in computer clusters for learners to use when learning how to code, but giving learners access to MATLAB on their own computers is impractical, owing to the cost of licensing.

Dr João Quinta da Fonseca and Dr Chris Race have come up with a solution for their Materials Science 1st year undergraduates which provides learners with directly relevant examples and a chance to practise coding, without having to use University computer clusters or commercial software like MATLAB.

Using an open source application, Jupyter Notebook, the pair has been encouraging learners to engage with live coding examples in Python ™, where they can combine live code with text, equations, and images. Learners can read about various code examples, change the parameters, and run their code interactively in a web browser.  The Notebook supports over 40 different programming languages as well as Python™, including R, Julia, and Scala.

In their course units covering Core Skills (MATS15501) and Functional Properties & Environmental Interactions (MATS16302) João and Chris have provided an Anaconda download package, a distribution of Python made with scientists in mind, for learners to install on their personal computers.  Once installed, learners can launch a blank Jupyter notebook and either start coding, or add one of the assessment notebooks designed for the course units and manipulate the code, learning how to code by performing data and image analysis, and modelling tasks relevant to materials science.

Jupyter Notebook is a web application, and although currently learners run a server on their own computer.  João and Chris are keen to investigate whether a Notebook server could be implemented Faculty wide, with access controlled through the University’s central authentication system and with access to the learner’s file space, to make it easier for learners to start working with Jupyter Notebook. This would also encourage wider use of this resource and help share good practice across the Faculty’s Schools. A trial version which can be run in a web browser is available here:  https://try.jupyter.org/

If you are interested in exploring the possibility of using Jupyter Notebooks in teaching, please get in touch with the eLearning Team.