nl en

Hacking the Humanities: An Introduction to Python and Text Mining


Admission requirements

Please note students of the Minor Digital Humanities have priority. Students from other programmes can only be admitted if there are places left. Students from other programmes interested in taking this course are kindly requested to contact the Coordinator of Studies and the lecturer, if you are interested in taking this course but are not a student of the minor Digital Humanities. See also under registration below.


This course is an introduction to the Python programming language for students without prior programming experience. We will cover core programming concepts like data structures, conditionals, loops, variables and functions. Students will also learn the basics of natural language processing and text mining. At the end of the course students will be able to use Python programming language to extract valuable insights from unstructured text and answer a variety of questions in the humanities.

No programming knowledge or technical expertise is assumed.

Course objectives

At the end of the course, the students will:

  • develop a basic understanding of programming and the Python programming language;

  • be able to write a Python program that can automatically extract, analyze and visualize information from text corpora;

  • get familiar with computer-aided research methodologies in various humanities disciplines.


The timetables are avalable through My Timetable.

Mode of instruction

  • Lectures

  • Workgroups/tutorials

Assessment method


  • Assignments

  • Final Project


  • Assignments: (20 percent of grade)

  • Final Project: (80 percent of grade)

In order to pass the course, students must have a grade of at least 5.5 for both Assignments and the Final Exam.The final mark for the course is established by determining the weighted average.


Students who have scored an insufficient grade for the final project may take a resit. It is not possible to take a resit for the assignments.

Inspection and feedback

How and when an exam review will take place will be disclosed together with the publication of the exam results at the latest. If a student requests a review within 30 days after publication of the exam results, an exam review will have to be organized.

Reading list

The up-to-date syllabus, which includes all of the readings for the course, will be posted on Brightspace.


Enrolment through My Studymap (Login | Universiteit Leiden) is mandatory.


  • For substantive questions, contact the lecturer listed in the right information bar.

  • For questions about enrolment, admission, etc., contact the Education Administration Office: Reuvensplaats.


Attendance and active participation are obligatory. Students are required to prepare for and attend all sessions. The convenor needs to be informed without delay of any classes missed for a good reason (i.e. due to unforeseen circumstances such as illness, family issues, problems with residence permits). The maximum of such absences during a semester is two. Being absent without notification and/or more than two times can result in exclusion from the term end exams and a failing grade for the course.